API problem with kick function. #2394

Closed
xxFlare opened this Issue Dec 12, 2014 · 6 comments

Projects

None yet

3 participants

@xxFlare
xxFlare commented Dec 12, 2014

Kick function is not working properly as it used too.

$player->kick("Reason");

Will crash the whole server when executed.

Picture of console error; http://prntscr.com/5fvdrh

@xxFlare
xxFlare commented Dec 12, 2014

It worked fine in older builds such as #650

@shoghicp shoghicp added the C: API label Dec 12, 2014
@shoghicp
Member

It seems like you are kicking the player between some special calls, could you point out on which event?

@shoghicp shoghicp added a commit that referenced this issue Dec 12, 2014
@shoghicp shoghicp Possible fix for #2394 c81bbda
@xxFlare
xxFlare commented Dec 12, 2014

Here is the code.

http://prntscr.com/5g3fqx

@iksaku
Contributor
iksaku commented Dec 12, 2014

It works perfectly for me :/

@xxFlare
xxFlare commented Dec 12, 2014

Its not only me, Some people where complaining about this problem on a similar plugin too (http://forums.pocketmine.net/threads/advertisingkick.4311/) that worked fine in older builds such as #650. Im not sure if its the same cause but something seems to be wrong with the kick function.

Mabe something related with kicking a player on player interact event?

I can give you the plugin if you want.

@xxFlare
xxFlare commented Dec 12, 2014

Ok it seems like its starting to work again with the latest possible fix. :D

@xxFlare xxFlare closed this Dec 12, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment