I'm trying to create 2 things via script:
1 - Something that will show my points in the HUD
2 - Delay Heal (After 5 seconds without taking damage, you will heal 1 HP per 0,1 second (+10 HP per second)
Here, I will show to you guys each script
1 -
The XP part is working, it was made to show to you every time that you kill someone or capture a flag, you get 100 points
The problem on the XP show: I can't get it to work, every time that i try it there's an error on the console:
LUA ERROR: sys/lua/autorun/classes.lua:67: ')' expected near 'Points'
PS: The line 67 is the line 24 on the spoiler
PSS: the "XPP" was made to show and calculate my points (eg. After every kill - XPP = XPP + 1)
The second error
2-
What I tried here:
- On the function MOHII, if you have 100HP or more, the timer will be 0 (the timer is HHP). If you have less than 100HP, when the timer reaches 5 seconds, the HPP(the quantity of HP that will be healed) will be 1.
The function MOHIT is working normaly (if I replace the HPP with 1, it will work, but without delay)
When I use both, there's no console error and even after 5 seconds, I'm not being healed.
Thank you guys for helping me!