English Incorrect code message

23 replies
Goto Page
To the start Previous 1 2 Next To the start
05.08.18 12:04:35 am
Up
Rainoth
Moderator
Offline Off
@user Whealtey: You probably missed although it's really obvious but user Quattro was satirizing user phalenkO's code and wrote his own code to look poorly.
@user Quattro: Don't do what you did even if you can see that the author of this thread is asking for handouts.
05.08.18 11:13:55 am
Up
Quattro
User
Offline Off
user Whealtey has written:
Code:
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!!
05.08.18 04:21:17 pm
Up
Whealtey
User
Offline Off
@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
loading...
05.08.18 07:28:22 pm
Up
Quattro
User
Offline Off
@user Whealtey:
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