GameTextForPlayer not working
#1

Hi there,

I have little problem with GameTextForPlayer, when player pickup some pickup it should show GameText of pickup, it works fine when i call it in OnPlayerPickUpPickup, but when i call it from OnPlayerPickUpDynamicPickup, it doesn't show text, as you can see in code i print some of information's i need, and in Dynamic call back it prints good in console, but i won't show gametext.

Here is code:

pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid){
    for(new i = 1; i < sizeof(ePickupInfo); i++){
        if(pickupid == ePickupInfo[i][epPID]){
            printf("%d %d %d, %s", pickupid, ePickupInfo[i][epPID], ePickupInfo[i][epSQLID], ePickupInfo[i][epDiscription]);
            format(globalstring, sizeof(globalstring), "%s", ePickupInfo[i][epDiscription]);
            return GameTextForPlayer(playerid, globalstring, 3000, 5);
        }
    }
    return true;
}

public OnPlayerPickUpDynamicPickup(playerid, pickupid)
{
    for(new i = 1; i < sizeof(ePickupInfo); i++){
        if(pickupid == ePickupInfo[i][epPID]){
            printf("%d %d %d, %s", pickupid, ePickupInfo[i][epPID], ePickupInfo[i][epSQLID], ePickupInfo[i][epDiscription]);
            format(globalstring, sizeof(globalstring), "%s", ePickupInfo[i][epDiscription]);
            return GameTextForPlayer(playerid, globalstring, 3000, 5);
        }
    }
    return 1;
}
Reply


Messages In This Thread
GameTextForPlayer not working - by CoaPsyFactor - 09.06.2012, 14:00
Re: GameTextForPlayer not working - by JhnzRep - 09.06.2012, 14:07
Re: GameTextForPlayer not working - by CoaPsyFactor - 09.06.2012, 14:12
Re: GameTextForPlayer not working - by ikey07 - 09.06.2012, 14:25
Re: GameTextForPlayer not working - by CoaPsyFactor - 09.06.2012, 17:25

Forum Jump:


Users browsing this thread: 3 Guest(s)