14.08.2015, 19:13
So along with all my variables I got this up top;
Now, for the tutorial I got this which creates the actor inside a binco with a special virtual world (player's virtual world is set to this as well)
Once the player exits the binco from the tutorial, the actor gets destroyed(no need for an actor anymore because he isnt being seen)
And under OnPlayerConnect I have this
Along with a whole bunch of variables that are reset.
The weird thing, those are the only 2 times an actor gets destroyed (onplayerconnect and when the actor isnt visible anymore)
Yet, (tested with 3 people at same time)
Here's how it went
1st player(me) joins, gets halfway in tutorial with no bugs/mistakes/errors whatsoever.
2 minutes after: 2nd player(friend of mine) connects to have a peek at the tutorial I made, but once he connects somehow my actor is being destroyed?
1 minute after 2nd player join: 3rd player joins and actor for 2nd player disappears.
Is there anything I did wrong?
Code:
new TutorialActor[MAX_PLAYERS][3],
Code:
//onplayerspawn i if(!pData[playerid][pTutorialFinished]) // and some more code TutorialActor[playerid][0] = CreateActor(211, 208.8536,-98.6901,1005.2578,179.5417); // here the actor is made SetActorVirtualWorld(TutorialActor[playerid][0], 6969+playerid);
Code:
DestroyActor(TutorialActor[playerid][0]);
Code:
DestroyActor(TutorialActor[playerid][0]);
The weird thing, those are the only 2 times an actor gets destroyed (onplayerconnect and when the actor isnt visible anymore)
Yet, (tested with 3 people at same time)
Here's how it went
1st player(me) joins, gets halfway in tutorial with no bugs/mistakes/errors whatsoever.
2 minutes after: 2nd player(friend of mine) connects to have a peek at the tutorial I made, but once he connects somehow my actor is being destroyed?
1 minute after 2nd player join: 3rd player joins and actor for 2nd player disappears.
Is there anything I did wrong?