Tutorial only appears for ID 0
#1

I ask for help, I'm racking my brain to try to figure out why the tutorial only appears for id 0, and when another player enters the id 0 back to the beginning of the tutorial ...

Code that call the tutorial:
http://pastebin.com/mrZ9Fxdn
Reply
#2

can you show us where you're calling MySQL_Login?
Reply
#3

Here it is:
http://pastebin.com/Zc5HHsk7
Reply
#4

Post the function IniciarTuto please.
Reply
#5

PHP код:
forward IniciarTuto(playerid);
public 
IniciarTuto(playerid)
{
    
Tuto[playerid] = 1;
    
ProxTuto[playerid] = 1;
    
SetPlayerCameraPos(playerid, -2535.52811302.938278.0744);
    
SetPlayerCameraLookAt(playerid, -2536.05711303.784177.8044);
    for(new 
i=0;i<11;++iPlayerTextDrawShow(playeridTutorialTD[i]);
    
SetTimerEx_("PularTuto"20000200001"d"playerid);
    return 
1;

Reply
#6

Please post all functions in timers...
I need PularTuto

And if there is any timers.. I need them too..
Reply
#7

PHP код:
forward PularTuto(playerid);
public 
PularTuto(playerid)
{
    if(
Tuto[playerid] == 1)
    {
        
PodePular[playerid] = 1;
    }
    else
    {
        
Tuto[playerid] = 0;
        
ProxTuto[playerid] = 0;
        
TogglePlayerSpectating(playerid0);
        for(new 
i=0;i<11;++iPlayerTextDrawHide(playeridTutorialTD[i]);
    }
    return 
1;

PHP код:
if(oldkeys KEY_SECONDARY_ATTACK)
{
    if(
Tuto[playerid] == 1)
    {
        if(
PodePular[playerid] == 1)
        {
            for(new 
i=1;i<11;++iPlayerTextDrawHide(playeridTutorialTD[i]);
            if(
ProxTuto[playerid] < 15)
            {
                
ProxTutor(playerid);
            }
            else
            {
                
PlayerTextDrawHide(playeridTutorialTD[0]);
                
Tuto[playerid] = 0;
                
ProxTuto[playerid] = 0;
                
PodePular[playerid] = 0;
                
TogglePlayerSpectating(playerid0);
            }
            return 
1;
        }
    }
    return 
1;

ProxTutor(playerid)
http://pastebin.com/kiqbQaDt
Reply
#8

AFAK you should not need a playerid in the array but according to your code and the symptoms..
You will have to use an index for the playerid.

Код:
new PlayerText:TutorialTD[11][MAX_PLAYERS]
Reply
#9

You think replacing it:
PHP код:
new PlayerText:TutorialTD[11
By this:
PHP код:
new PlayerText:TutorialTD[11][MAX_PLAYERS
It will work?
Reply
#10

@Resolved

I checked all gamemode then able to find the error in SetTimerEx_
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)