Forum

> > CS2D > Scripts > Error with a script
Forums overviewCS2D overview Scripts overviewLog in to reply

English Error with a script

2 replies
To the start Previous 1 Next To the start

old Error with a script

ExecL
User Off Offline

Quote
im trying to make a script. but it has Errors if
you could fix it for me i would be so happy

im trying to make it. so if you say "password" it opens
a specified dyn_wall and if your 2 tiles away from it. it does not work. the name of the dyn_wall would be 'admindoor' so if you could i would love you.

1
2
3
4
5
6
7
8
9
addhook("say"trigger")
function say(txt,trigger)
    if txt == "password" then
    if func_dynwallname == "admindoor" then
          parse("trigger..func_dynwall "admindoor")
          end
         return 1
     end
end

old Re: Error with a script

Dovahkin
User Off Offline

Quote
Try this? hahaha i didnt test it haha!

1
2
3
4
5
6
7
addhook("say"trigger")
function say(txt,trigger)
	if(txt == "password") then
		parse("trigger admindoor")
	end
end
end

Tell me the problem later. if it doesn't work.

old Re: Error with a script

Cure Pikachu
User Off Offline

Quote
@user Dovahkin: The script won't work.

This one's the fixed version.
1
2
3
4
5
6
addhook("say","trigger2")
function trigger2(id,txt)
	if txt == "password" then
		parse("trigger admindoor")
	end
end
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview