Post: Script Error "kick"
02-11-2016, 10:50 PM #1
KrazyKandy
I am error
(adsbygoogle = window.adsbygoogle || []).push({}); Im honestly not sure about this error

You must login or register to view this content.

The following user groaned KrazyKandy for this awful post:

John
02-11-2016, 10:55 PM #2
HiddenHour
I defeated!
Originally posted by KrazyKandy View Post
Im honestly not sure about this error

You must login or register to view this content.


How are you calling the function?
02-11-2016, 11:02 PM #3
KrazyKandy
I am error
Originally posted by TheHiddenHour View Post
How are you calling the function?


I dont even have "kick" in here. I have this
    kickAllBots()
{
foreach(player in level.players)
{
if(isDefined(player.pers["isBot"])&&player.pers["isBot"])kick(playergetEntityNumber(),"EXE_PLAYERKICKED");
}
}
02-11-2016, 11:10 PM #4
HiddenHour
I defeated!
Originally posted by KrazyKandy View Post
I dont even have "kick" in here. I have this
    kickAllBots()
{
foreach(player in level.players)
{
if(isDefined(player.pers["isBot"])&&player.pers["isBot"])kick(playergetEntityNumber(),"EXE_PLAYERKICKED");
}
}


    kickAllBots()
{
foreach(player in level.players)
{
if(isDefined(player.pers["isBot"])&&player.pers["isBot"])
[B]kick[/B](playergetEntityNumber(),[B][I]"EXE_PLAYERKICKED"[/I][/B]);
}
}

What is the purpose of EXE_PLAYERKICKED? I believe the kick function only has one argument which is the client number.
02-11-2016, 11:24 PM #5
jwm614
NextGenUpdate Elite
Originally posted by TheHiddenHour View Post
    kickAllBots()
{
foreach(player in level.players)
{
if(isDefined(player.pers["isBot"])&&player.pers["isBot"])
[B]kick[/B](playergetEntityNumber(),[B][I]"EXE_PLAYERKICKED"[/I][/B]);
}
}

What is the purpose of EXE_PLAYERKICKED? I believe the kick function only has one argument which is the client number.


yes you are correct
02-12-2016, 05:41 PM #6
seanhellen
Are you high?
shouldn't it be
    
kick(player getentitynumber())


1 arg and a space after player?
02-12-2016, 05:51 PM #7
Originally posted by seanhellen View Post
shouldn't it be
    
kick(player getentitynumber())


1 arg and a space after player?


That's correct
02-12-2016, 07:00 PM #8
seanhellen
Are you high?
Originally posted by John View Post
That's correct



Its strange as the game freezes when i have kick in the menu using this code. Dont know why. Ssme with ban
02-12-2016, 09:31 PM #9
BullyWiiPlaza
Climbing up the ladder
Originally posted by seanhellen View Post
Its strange as the game freezes when i have kick in the menu using this code. Dont know why. Ssme with ban

kick takes the entity number as argument and that's it:
    kickPlayer(player)
{
kick(player getEntityNumber());
}

It definitely works since I'm using it. Snail
02-12-2016, 09:37 PM #10
seanhellen
Are you high?
Facepalm Just noticed, I didn't have the player arg - I just had kick() Happy

Sorry, didn't mean to thread hi-jack

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo