when player dies, not onplayerspawn gets called?
#1

hey guys,

im trying to make it that when a player connects, he gets a menu with dialogs etc, that works fine, but i want that when he dies he doesnt gets that dialog and menus etc, but he just spawns without all that, so i mean onplayerspawn doesnt gets called... but i cant get it fixed , also OnPlayerRequestSpawn doesnt works also , anyone knows how to fix?

greets niels
Reply
#2

Maybe try to put them OnPlayerConnect
Reply
#3

how you mean? put them when die at onplayerconnect? and how?
Reply
#4

I mean put dialogues OnPlayerConnect
Reply
#5

Can you give us your OnPlayerRequestClass,OnPlayerSpawn and OnPlayerDeath so we can help you with your problem?
Reply
#6

It's easy.

Make a player variable;

pawn Код:
new DialogShown[MAX_PLAYERS] = 0;

public OnPlayerConnect(playerid)
{
    DialogShown[playerid] = 0;

    if(DialogShown[playerid] == 0)
    {
        //your code
        DialogShown[playerid] = 1;
    }
    //Rest of your code
}
There mate.
Reply
#7

ah yeah never thought of a simple variable XD thnx gonna try it out
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)