regen health please...
Forum
CS2D Scripts regen health? luaregen health? lua
4 replies 1
regen health please...
1
2
3
4
5
6
2
3
4
5
6
addhook("second","second") function second() 	for _, id in pairs(player(0, "tableliving")) do 		parse("sethealth "..id.." "..(player(id,"health") + 1)) 	end end
Another tip:
If you want to regen health faster, change hook and function to ms100. If you want it to regen much faster, use always.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
2
3
4
5
6
7
8
9
10
11
12
13
14
15
interval = 250 --time in milliseconds between each health regen amount = 2 --amount of health regenerated each regen function customTimer() 	regen() 	timer(interval, 'customTimer') end customTimer() function regen() 	for _,id in pairs(player(0, 'tableliving')) do 		parse('sethealth '..id..' '..(player(id, 'health') + amount) 	end end
It's doesn't work at server.
edited 1×, last 22.12.13 10:40:49 pm
1