Forum

> > CS2D > Scripts > Help to reset scoree!
Forums overviewCS2D overview Scripts overviewLog in to reply

English Help to reset scoree!

12 replies
To the start Previous 1 Next To the start

old Help to reset scoree!

Noswear222
User Off Offline

Quote
Hello everyone's unreal, I wanted one and it helps to reset the score more if the score is 0 in a message similar to the N ~ Prison

addhook("say" , "say_score")
function say_score(id,txt)

     if(txt=="!resetscore") then
     parse("setscore "..id.." 0")
     parse("setdeaths "..id.." 0")
AND MORE...
edited 3×, last 10.05.11 06:31:20 pm

old Re: Help to reset scoree!

Surplus
User Off Offline

Quote
1
2
3
4
5
6
7
8
addhook("say","pedobear")
function pedobear(id,txt)
	if (txt=="!pedobear") then
		parse ("setscore "..id.." 0")
		parse ("setdeaths "..id.." 0")
		parse ("sv_msg2 "..id.." ©000255000Your score has been reseted!")
	end
end


or something like that

If it wount work (doesnt reset score), Yates is correct.
If it sends a error, dont ask me.

EDIT: Forgot to add 'then'
EDIT2: Forgot to add another 'end'
EDIT3:There is an error i dont know how to fix. Enjoy fixing it yourself.

old Re: Help to reset scoree!

Homam
User Off Offline

Quote
Here's a better script, found it somewhere.

1
2
3
4
5
6
7
8
9
sc = "0"

addhook("say","resets")
	function resets(id, txt)
		if (txt=="!rs") then
		parse ("setscore "..id.." ..sc")
		parse ("setdeaths "..id.." ..sc")
	end
end

old Re: Help to reset scoree!

DannyDeth
User Off Offline

Quote
Hopelessness defined in some of the previous posts of this thread.
1
2
3
4
5
6
7
addhook("say","reset_score")
function reset_score(id,txt)
	if txt=="!rs" then
		parse("setscore "..id.." 0")
		parse("setdeaths "..id.." 0")
	end
end
There, simple. And it actually works.

See:
cs2d cmd setscore
cs2d cmd setdeaths
for some infomation on the code.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview