Forum

> > CS2D > Scripts > Incorrect code message
Forums overviewCS2D overview Scripts overviewLog in to reply

English Incorrect code message

23 replies
Page
To the start Previous 1 2 Next To the start

old Re: Incorrect code message

Quattro
GAME BANNED Off Offline

Quote
user Cebra has written
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
d = 50
for i = 1, d do
	if player(1,'exists') then
		if player(1,'team')==1 then
			if player(1,'health')>0 then
				if player(1,'health')<50 then
					msg2(1,'this is a nice piece of new generation style code')
				end
			var = 'kids are stupid'
			end 
		parse('restart')
		end
	msg(var)
	end
return
end

@user Quattro:
you missed the do after the for-statement (line 2)

this code will throw an error message, if player 1 is dead and it is executed, because the variable var is unknown.
But why do you use a for-Loop, in this case it is pointless.
please tab your code

@user phalenkO:
you get the error-message because your message wasn't "!kick <id>"
remove the else-statement to avoid this


Thank you for fixing my serious script! You make my life so much easier, now I can create another happy town server with this script!!

old Re: Incorrect code message

Cebra
User Off Offline

Quote
@user Quattro: sorry, didn't get it, but why did you post something, if you are not willing to help. Some people have problems to learn such things, especially in a foreign language

old Re: Incorrect code message

Quattro
GAME BANNED Off Offline

Quote
@user Cebra:
Last time I helped some kid he later copy paste exact script from before and ask to add a variable for him. Also told me he knows how to edit my FKing script and he just needs another var

Give the man a fish and you feed him for a day, teach a man to fish and you feed him for a lifetime.

I suggest you try out the later one some time
To the start Previous 1 2 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview