Kleine AnimationsHilfe für Anfänger

In 10 Minuten startet der nächtliche Backupvorgang! Es kann währenddessen (ca. 10 Minuten) zu Einschränkungen bei der Nutzung des Forums kommen
Weitere Infos findet ihr im Thema Backup des Forums
Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Einfach Irgendwohin Am Besten Ganz Unten
    "Für Anfänger"


    OnePlayAnim(playerid,animlib[],animname[], Float:Speed, looping, lockx, locky, lockz, lp)
    {
    ApplyAnimation(playerid, animlib, animname, Speed, looping, lockx, locky, lockz, lp);
    }


    LoopingAnim(playerid,animlib[],animname[], Float:Speed, looping, lockx, locky, lockz, lp)
    {
    gPlayerUsingLoopingAnim[playerid] = 1;
    ApplyAnimation(playerid, animlib, animname, Speed, looping, lockx, locky, lockz, lp);
    //TextDrawShowForPlayer(playerid,txtAnimHelper);
    }
    Ganz Oben
    new PeeTimer[MAX_PLAYERS];
    new gPlayerUsingLoopingAnim[MAX_PLAYERS];



    Zu OnDialogResponse:


    if(dialogid == DIALOG_ANIM)
    {
    if(response)
    {
    if(listitem == 0) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_HANDSUP); }
    if(listitem == 1) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_USECELLPHONE); }
    if(listitem == 2) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_STOPUSECELLPHONE); }
    if(listitem == 3) { SetPlayerSpecialAction(playerid, SPECIAL_ACTION_SITTING); }
    if(listitem == 4) {
    SetPlayerSpecialAction(playerid, 68);
    PeeTimer[playerid] = SetTimerEx("Harndrang",8000,0,"i",playerid);
    }
    if(listitem == 5) { LoopingAnim(playerid,"PED","WALK_DRUNK",4.0,1,1,1,1,0); }
    if(listitem == 6) {
    ClearAnimations(playerid);
    OnePlayAnim(playerid, "BOMBER", "BOM_Plant", 4.0, 0, 0, 0, 0, 0); // Place Bomb
    }
    if(listitem == 7) { LoopingAnim(playerid,"ped", "ARRESTgun", 4.0, 0, 1, 1, 1, -1); }
    if(listitem == 8) { OnePlayAnim(playerid, "RAPPING", "Laugh_01", 4.0, 0, 0, 0, 0, 0); }
    if(listitem == 9) { OnePlayAnim(playerid, "SHOP", "ROB_Shifty", 4.0, 0, 0, 0, 0, 0); }
    if(listitem == 10) { LoopingAnim(playerid, "SHOP", "ROB_Loop_Threat", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 11) { LoopingAnim(playerid, "COP_AMBIENT", "Coplook_loop", 4.0, 0, 1, 1, 1, -1); }
    if(listitem == 12) { LoopingAnim(playerid,"BEACH", "bather", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 13) { LoopingAnim(playerid, "ped", "cower", 3.0, 1, 0, 0, 0, 0); }
    if(listitem == 14) { OnePlayAnim(playerid, "FOOD", "EAT_Vomit_P", 3.0, 0, 0, 0, 0, 0); }
    if(listitem == 15) { OnePlayAnim(playerid, "FOOD", "EAT_Burger", 3.0, 0, 0, 0, 0, 0); }
    if(listitem == 16) { LoopingAnim(playerid, "ON_LOOKERS", "wave_loop", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 17) { OnePlayAnim(playerid, "SWEET", "sweet_ass_slap", 4.0, 0, 0, 0, 0, 0); }
    if(listitem == 18) { OnePlayAnim(playerid, "DEALER", "DEALER_DEAL", 4.0, 0, 0, 0, 0, 0); }
    if(listitem == 19) { LoopingAnim(playerid, "CRACK", "crckdeth2", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 20) { LoopingAnim(playerid,"SMOKING", "M_smklean_loop", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 21) { LoopingAnim(playerid, "SMOKING", "F_smklean_loop", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 22) { LoopingAnim(playerid,"BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0); }
    if(listitem == 23) { OnePlayAnim(playerid,"PED","IDLE_CHAT",4.0,0,0,0,0,0); }
    if(listitem == 24) { OnePlayAnim(playerid,"PED","fucku",4.0,0,0,0,0,0); }
    if(listitem == 25) { LoopingAnim(playerid,"PARK","Tai_Chi_Loop",4.0,1,0,0,0,0); }
    if(listitem == 26) { LoopingAnim(playerid,"BAR","dnk_stndF_loop",4.0,1,0,0,0,0); }
    if(listitem == 27) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_DANCE1); }
    if(listitem == 28) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_DANCE2); }
    if(listitem == 29) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_DANCE3); }
    if(listitem == 30) { SetPlayerSpecialAction(playerid,SPECIAL_ACTION_DANCE4); }
    if(listitem == 31) {
    if(!IsPlayerInAnyVehicle(playerid))
    {
    ClearAnimations(playerid);
    }
    }
    }
    return 1;
    }


    ocmd:anim(playerid,params[]) {
    new string1[200],string2[200],rest[400];
    format(string1,sizeof(string1),"Handsup\nCellin\nCellout\nSit\nPinkeln\nBetrunken\nBomb\nGet Arrested\nLache\nLookout\nRobman\nCrossarms\nLay\nHide\n");
    format(string2,sizeof(string2),"Vomit\nEat\nWave\nSlapass\nDeal\nSex\nSmoke M\nSmoke F\nGrounsit\nChat\nFuck you\nTaichi\nChairsit\nDance 1\nDance 2\nDance 3\nDance 4\nStop Animation");
    format(rest,sizeof(rest),"%s\n%s\n",string1,string2);
    ShowPlayerDialog(playerid,DIALOG_ANIM,DIALOG_STYLE_LIST,"Animationen",rest,"Ok","Abbrechen");
    return 1;
    }


    So Viel Spaß Damit Bei Errors einfach Posten =)


    :D