OnPlayerSpawn not being called on gamemode
#1

I have 1 gamemode and 4 Filterscripts. I'm using OnPlayerSpawn in 2 of the filterscripts. Apparently OnPlayerSpawn only gets called from one filterscript and doesn't get called in the gamemode. Why does that happen?
BTW all the OnPlayerSpawn callbacks return 1 ofc.

Also, my config file filterscripts order (if that matters):

(a filterscript that uses OnPlayerSpawn) (The filterscript where OnPlayerSpawn gets called from) (2 other filterscripts)
Reply
#2

bump, I really need help with this.
Reply
#3

all of your filterscripts and gamemodes MUST return 1 when they are finished with OnPlayerSpawn for all of them to trigger. Usually the rule of thumb is to always return 0 with events in filterscripts but it looks like OnPlayerSpawn needs to return 1 for some reason.
Reply
#4

On the problematic filterscript I changed its return to 0 and it still triggered perfectly..

I still need help here.
Reply
#5

bump :/
Reply
#6

You must've return at some point in one of those filter scripts.
Btw all OnPlayerSpawn call backs return 1.
Reply
#7

Quote:
Originally Posted by YoYo123
Посмотреть сообщение
On the problematic filterscript I changed its return to 0 and it still triggered perfectly..

I still need help here.
Yes the one that returns 0 will work fine, but all the ones AFTER it will not trigger if you return 0 - you must always return 1. Also make sure that nothing else in that event happens to return 0, otherwise if that if code or whatever gets executed, it would return 0 and goof up all the other filterscripts.
Reply
#8

What about "onplayerequestspawn"?
Reply
#9

I checked all OnPlayerSpawn callbacks and they all return 1.

Quote:
Originally Posted by Dex007HLH
What about "onplayerequestspawn"?
They all return 1, nothing in either of them.
Reply


Forum Jump:


Users browsing this thread: 5 Guest(s)