• 23 Avril 2025, 07:36:40


Auteur Sujet: j'ai oublier quoi ?  (Lu 568 fois)

0 Membres et 1 Invité sur ce sujet

Hors ligne Leonidas300

  • *
  • Bandit
  • Pawno-Amateur, a déjà crée plusieurs système
  • Messages: 301
    • Voir le profil
j'ai oublier quoi ?
« le: 23 Août 2010, 22:33:23 »
Salut, voila j'ai copier un systeme d'un GM anglais, pour l'amélioré et le traduire, mais IG quand j'arrive à 20hp normalement sa me tue et me propose de /accepter mort ou d'attendre les secours
Mais IG quand j'arrive à 20hp le serveur crash, donc voila j'ai oublier quelques chose ou pas ?

Code: (pawn) [Sélectionner]
if(gPlayerLogged[i] == 1 && FirstSpawn[i] == 0)
        {
        new Float:health;
GetPlayerHealth(i, health);
if (health <= 20 && dying[i] == 0)
{
    if(!(IsPlayerInAnyVehicle(i)))
{
    format(string, sizeof(string), "* %s falls on the floor", GetPlayerName(i));
ProxDetector(15.0, i, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
SendClientMessage(i, COLOR_WHITE, "   You are dying now , you can wait for medic or you can use '/accept death' ");
printf("%s", string);
    TogglePlayerControllable(i, 0);
    ApplyAnimation(i,"PED","KO_skid_front",4.1,0,1,1,1,0);
    gPlayerUsingLoopingAnim[i] = 1;
dying[i] = 1;
}
else
{
    format(string, sizeof(string), "* %s loses consciousness", GetPlayerName(i));
    TogglePlayerControllable(i, 0);
ProxDetector(15.0, i, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
printf("%s", string);
    //ApplyAnimation(i,"PED","KO_skid_front",4.1,0,1,1,1,0);
dying[i] = 1;
}
}
else if (health >= 25 && dying[i] == 1)
{
                    if(!(IsPlayerInAnyVehicle(i)))
{
    format(string, sizeof(string), "* %s wakes up", GetPlayerName(i));
ProxDetector(15.0, i, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
printf("%s", string);
    TogglePlayerControllable(i, 1);
    ApplyAnimation(i,"PED","getup_front",4.1,0,1,1,0,1);
    gPlayerUsingLoopingAnim[i] = 0;
    //hostimer[i] = SetTimerEx("EnterHospital",3000,0,"i",i);
dying[i] = 0;
}
else
{
    format(string, sizeof(string), "* %s wakes up", GetPlayerName(i));
ProxDetector(15.0, i, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
TogglePlayerControllable(i, 1);
//hostimer[i] = SetTimerEx("EnterHospital",3000,0,"i",i);
printf("%s", string);
    //ApplyAnimation(i,"PED","KO_skid_front",4.1,0,1,1,1,0);
dying[i] = 0;
}
}
}




Zombi PAWN,Créateur de *** ****** ********* !

Cherche hébérgement SA:MP! [PM Moi]
Merci à vous

Hors ligne dydjyz

  • *
  • Bandit
  • Messages: 278
    • Voir le profil
    • OriginalRP - SAMP
Re : j'ai oublier quoi ?
« Réponse #1 le: 23 Août 2010, 23:16:26 »
TU a bien pris les new, les fonction etc ? (si il y en a ?)