Beiträge von Narushi

    also ein Timer der immer wieder jede sekunde den string neu zeigt?


    public UpdateKills();
    {
    TextDrawDestroy(tdk);
    format(evk,sizeof(evk),"%s : %i",GetName(i),killzahl);
    TextDrawSetString(tdk,evk);
    TextDrawShowForAll(tdk);
    return 1;
    }


    Code
    C:\Users\Narushi\Desktop\samp\World of San Andreas 4.0.2\gamemodes\WorldofSanAndreas.pwn(55242) : error 055: start of function body without function header
    C:\Users\Narushi\Desktop\samp\World of San Andreas 4.0.2\gamemodes\WorldofSanAndreas.pwn(55247) : error 010: invalid function or declaration
    Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase
    
    
    
    
    2 Errors.

    Hey,


    ich wollte per TextDraw meine DM-Points anzeigen beim Event..


    Doch: Wie mache ich, dass sich die Punkte immer aktualisieren?



    ocmd:points(playerid,params[])
    {
    if(PlayerInfo[playerid][pAdmin] >= 5)
    {
    if(killevent == 0)
    {
    for(new i=0; i<MAX_PLAYERS; i++)
    {
    new evk[256];
    tdk = TextDrawCreate(259, 26.1, "evki");
    TextDrawFont(tdk , 2);
    TextDrawLetterSize(tdk , 1, 7);
    TextDrawColor(tdk , 0xFFFF00FF);
    TextDrawSetOutline(tdk , 1);
    TextDrawSetProportional(tdk , 1);
    killzahl[i] = 0;
    killevent = 1;
    format(evk,sizeof(evk),"%s : %i",GetName(i),killzahl);
    TextDrawSetString(tdk,evk);
    TextDrawShowForAll(tdk);
    return 1;
    }
    }
    if(killevent == 1)
    {
    TextDrawDestroy(tdk);
    }
    }
    SendClientMessage(playerid,COLOR_GREY,"Du bist nicht befugt!");
    return 1;
    }


    new str[128];
    format(str,sizeof(str),"Bla");
    format(str,sizeof(str),"%s\n Bla",str);
    format(str,sizeof(str),"%s\n Bla",str);
    format(str,sizeof(str),"%s\n Bla",str);
    format(str,sizeof(str),"%s\n Bla",str);
    format(str,sizeof(str),"%s\n Bla",str);


    ShowPlayerDialog(playerid,1139,DIALOG_STYLE_MSGBOX,"===[ Dein Status }===",str,"OK","");

    wie umständlich. :huh:


    einfach das, was bei onplayerconnect steht, in onplayerrequestclass oder wie das jetzt heisst packen.

    Wie geht es denn, wenn der Server neu ist?


    public OnPlayerRequestClass(playerid, classid)
    {
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
    }


    public OnPlayerConnect(playerid)
    {
    return 1;
    }


    dann steht in OnPlayerRequestClass nur "return 1;" das bringt doch nicht viel ^^

    Benutz doch mal die pwn Funktion. So kann es ja keiner lesen



    Function SetPlayerSpawn(playerid)
    {
    if(IsPlayerConnected(playerid))
    {
    if(PlayerInfo[playerid][pTot] == 1 && PlayerInfo[playerid][pLevel] > 1 && PlayerInfo[playerid][pJailed] == 0 && PlayerInfo[playerid][pGangJailed] == 0 && PlayerPaintballing[playerid] == 0)
    {
    //if(PlayerInfo[playerid][pZivispawn] == 0) // SF AREA
    if(IsPlayerInArea(playerid,-2999.9465,-2999.9978,-991.2031,2594.2344))
    {
    TogglePlayerControllable(playerid, 0);
    ResetPlayerWeapons(playerid);
    SetPlayerPos(playerid,-2655.4385,641.4149,51.1221);
    SetPlayerCameraPos(playerid, -2565.9475,660.0692,62.4913);
    SetPlayerCameraLookAt(playerid, -2655.4385,641.4149,51.1221);
    SetPlayerVirtualWorld(playerid, 0);
    SetPlayerInterior(playerid, 0);
    FreezePlayer(playerid);
    }
    // else if(PlayerInfo[playerid][pZivispawn] == 1) // LV AREA
    if(IsPlayerInArea(playerid, -973.9219,396.0000,2986.5720,2989.9180))
    {
    TogglePlayerControllable(playerid, 0);
    ResetPlayerWeapons(playerid);
    SetPlayerPos(playerid,1594.6398,1766.0209,24.6398);
    SetPlayerCameraPos(playerid, 1555.9191,1769.1615,20.4710);
    SetPlayerCameraLookAt(playerid, 1594.6398,1766.0209,24.6398);
    SetPlayerVirtualWorld(playerid, 0);
    SetPlayerInterior(playerid, 0);
    FreezePlayer(playerid);
    }
    else
    {
    TogglePlayerControllable(playerid, 0);
    ResetPlayerWeapons(playerid);
    SetPlayerPos(playerid,-2655.4385,641.4149,51.1221);
    SetPlayerCameraPos(playerid, -2565.9475,660.0692,62.4913);
    SetPlayerCameraLookAt(playerid, -2655.4385,641.4149,51.1221);
    SetPlayerVirtualWorld(playerid, 0);
    SetPlayerInterior(playerid, 0);
    FreezePlayer(playerid);
    }
    return 1;
    }
    if(IsPlayerNPC(playerid))
    {
    new botname[MAX_PLAYER_NAME];
    GetPlayerName(playerid, botname, sizeof(botname));
    if(!strcmp(botname, "NeuerBot", true))
    {
    PlayerInfo[playerid][pCarLic] = 1;
    PlayerInfo[playerid][pChar] = 255;
    PlayerInfo[playerid][pJob] = 14;
    SetPlayerSkin(playerid, 255);
    //PutPlayerInVehicle(playerid, car_BulletLS, 0);
    }
    }
    if(PlayerInfo[playerid][pTut] == 0 && !IsPlayerNPC(playerid))
    {
    gOoc[playerid] = 1; gNews[playerid] = 1; gFam[playerid] = 1;
    FreezePlayer(playerid);
    AtRegestration[playerid] = 1;
    RegistrationStep[playerid] = 1;
    //SendClientMessage(playerid, COLOR_YELLOW, " ");
    //SendClientMessage(playerid, COLOR_LIGHTRED, " Bist du Männlich oder Weiblich?");
    ShowPlayerDialog(playerid,DIALOG_REGSTEP_1,DIALOG_STYLE_MSGBOX,"Geschlecht","Gib bitte dein Geschlecht an.","Männlich","Weiblich");
    //----------------
    SetPlayerPos(playerid,1424.7075,-980.6817,53.9398);
    SetPlayerFacingAngle(playerid, 4.0557);
    SetPlayerInterior(playerid,0);
    SetPlayerCameraPos(playerid, 1431.3164,-975.2504,57.5156);
    SetPlayerCameraLookAt(playerid,1422.5352,-912.2574,76.5841);
    //ShowPlayerDialog(playerid,DIALOG_REGSTEP_1,DIALOG_STYLE_MSGBOX,"Geschlecht","Welches Geschlecht bist du?","Männlich","Weiblich");
    //ShowPlayerDialog(playerid,1,DIALOG_STYLE_INPUT,"Login to your account",s,"Login","Cancel");


    // ShowMenuForPlayer(Geschlecht,playerid);
    }
    if(PlayerInfo[playerid][pTut] == 0 && !IsPlayerNPC(playerid))
    {
    gOoc[playerid] = 1; gNews[playerid] = 1; gFam[playerid] = 1;
    FreezePlayer(playerid);
    AtRegestration[playerid] = 1;
    RegistrationStep[playerid] = 1;
    //SendClientMessage(playerid, COLOR_YELLOW, " ");
    //SendClientMessage(playerid, COLOR_LIGHTRED, " Bist du Männlich oder Weiblich?");
    //ShowPlayerDialog(playerid,DIALOG_REGSTEP_1,DIALOG_STYLE_INPUT,"Geworben","Von wem wordest du geworben ?","Weiter","abbrechen");
    //----------------
    SetPlayerPos(playerid,1424.7075,-980.6817,53.9398);
    SetPlayerFacingAngle(playerid, 4.0557);
    SetPlayerInterior(playerid,0);
    SetPlayerCameraPos(playerid,1431.3164,-975.2504,57.5156);
    SetPlayerCameraLookAt(playerid,1422.5352,-912.2574,76.5841);
    //ShowPlayerDialog(playerid,DIALOG_REGSTEP_1,DIALOG_STYLE_MSGBOX,"Geschlecht","Bist du Männlich oder Weiblich?","Erstellen","Abbrechen");
    //ShowPlayerDialog(playerid,1,DIALOG_STYLE_INPUT,"Login to your account",s,"Login","Cancel");


    // ShowMenuForPlayer(Geschlecht,playerid);
    }
    new rand;
    new house = PlayerInfo[playerid][pPhousekey];
    if(PlayerPaintballing[playerid] != 0)
    {
    ResetPlayerWeapons(playerid);
    GivePlayerWeapon(playerid, 29, 999);
    GivePlayerWeapon(playerid, 24, 999);
    rand = random(sizeof(PaintballSpawns));
    SetPlayerPos(playerid, PaintballSpawns[rand][0], PaintballSpawns[rand][1], PaintballSpawns[rand][2]);
    return 1;
    }
    if(KnastTime[playerid] > 0)
    {
    SetPlayerToKnast(playerid,Knast[playerid]);
    SendClientMessage(playerid, COLOR_LIGHTRED, "!Flüchten bringt nichts, zurück in die Zelle!");
    SetPlayerInterior(playerid,3);
    return 1;
    }
    if(PlayerInfo[playerid][pJailed] == 1)
    {
    SetPlayerInterior(playerid,3);
    SetPlayerPos(playerid,193.7812,162.1770,1003.0234);
    SetCameraBehindPlayer(playerid);
    PlayerInfo[playerid][pInt] = 3;
    TogglePlayerControllable(playerid, 1);
    SendClientMessage(playerid, COLOR_LIGHTRED, "!!Flüchten bringt nichts, zurück in die Zelle!");
    return 1;
    }
    if(PlayerInfo[playerid][pJailed] == 2)
    {
    SendClientMessage(playerid, COLOR_LIGHTRED, "Du wurdest wieder ins Gefängnis gebracht!");
    SetPlayerInterior(playerid,3);
    PlayerInfo[playerid][pInt] = 3;
    SetCameraBehindPlayer(playerid);
    ResetPlayerWeapons(playerid);
    TogglePlayerControllable(playerid, 1);
    SetPlayerPos(playerid,193.7812,162.1770,1003.0234);
    return 1;
    }
    if(PlayerInfo[playerid][pGangJailed] == 1)
    {
    SetPlayerInterior(playerid, 0);
    SetPlayerVirtualWorld(playerid, 0);
    SetPlayerPos(playerid, 218.9510,-231.8540,1.7786);
    SetCameraBehindPlayer(playerid);
    ResetPlayerWeapons(playerid);
    TogglePlayerControllable(playerid, 1);
    SendClientMessage(playerid, COLOR_LIGHTRED, " Du befindest dich noch im GangJail!");
    return 1;
    }
    if(house != 255)
    {
    if(SpawnChange[playerid]) //If 1, then you get to your house, else spawn somewhere else
    {
    GivePlayerWeapons(playerid);
    SetPlayerToTeamColor(playerid);
    SetPlayerInterior(playerid,HouseInfo[house][hInt]);
    SetPlayerPos(playerid, HouseInfo[house][hExitx], HouseInfo[house][hExity],HouseInfo[house][hExitz]); // Warp the player
    PlayerInfo[playerid][pLocal] = house;
    PlayerInfo[playerid][pInt] = HouseInfo[house][hInt];
    SetPlayerVirtualWorld(playerid,house);
    return 1;
    }
    }
    if (PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1)// Police
    {
    SetPlayerToTeamColor(playerid);
    GivePlayerWeapons(playerid);
    SetPlayerPos(playerid,216.5404,168.6841,1003.0234); // Warp the player
    SetPlayerFacingAngle(playerid,random(360));
    SetPlayerInterior(playerid,3);
    return 1;
    }
    if (PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2) //FBI
    {
    SetPlayerToTeamColor(playerid);
    SetPlayerInterior(playerid,6);
    GivePlayerWeapons(playerid);
    SetPlayerPos(playerid,216.5404,168.6841,1003.0234);
    SetPlayerFacingAngle(playerid,273.0);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(IsAnInstructor(playerid)) //Fahrschule spawn
    {
    if(SchoolSpawn[playerid] == 0)
    {
    SetPlayerToTeamColor(playerid);
    SetPlayerPos(playerid,-2022.2632,-116.6569,1035.1719);
    SetPlayerFacingAngle(playerid,4.7173);
    SetPlayerInterior(playerid,3);
    PlayerInfo[playerid][pInt] = 0;
    SetPlayerHealth(playerid, 100);
    GivePlayerWeapons(playerid);
    }
    else if(SchoolSpawn[playerid] == 1)
    {
    SetPlayerToTeamColor(playerid);
    SetPlayerPos(playerid,2145.5706,-1803.3696,16.1406);
    SetPlayerFacingAngle(playerid,4.7173);
    SetPlayerInterior(playerid,0);
    PlayerInfo[playerid][pInt] = 0;
    SetPlayerHealth(playerid, 100);
    GivePlayerWeapons(playerid);
    }
    return 1;
    }
    else
    {
    SetPlayerToTeamColor(playerid);
    /*if(PlayerInfo[playerid][pOrigin] == 1 || PlayerInfo[playerid][pOrigin] == 2 || PlayerInfo[playerid][pOrigin] == 3)
    {
    SetPlayerPos(playerid,-1423.1486,-287.0710,14.1484);// 922.7817,-919.9584,42.6016
    SetPlayerFacingAngle(playerid,358.8067);
    SetPlayerInterior(playerid,0);
    PlayerInfo[playerid][pInt] = 0;
    PlayerInfo[playerid][pRollerLic] = 1;
    PlayerInfo[playerid][pPhoneBook] = 1;
    }*/
    if(PlayerInfo[playerid][pZivispawn] == 0) // Los Santos
    {
    SetPlayerPos(playerid, 381.8524,-1828.7184,7.8359); // LS SPAWN
    SetPlayerFacingAngle(playerid,60.3900);
    SetPlayerInterior(playerid,0);
    PlayerInfo[playerid][pRollerLic] = 1;
    PlayerInfo[playerid][pPhoneBook] = 1;
    }
    else if(PlayerInfo[playerid][pZivispawn] == 1) // kp
    {
    SetPlayerPos(playerid,1683.0674,1447.9215,10.7717);
    SetPlayerFacingAngle(playerid,358.8067);
    SetPlayerInterior(playerid,0);
    PlayerInfo[playerid][pRollerLic] = 1;
    PlayerInfo[playerid][pPhoneBook] = 1;
    }
    else if(PlayerInfo[playerid][pZivispawn] == 2) // kp
    {
    SetPlayerPos(playerid,1683.0674,1447.9215,10.7717);
    SetPlayerFacingAngle(playerid,358.8067);
    SetPlayerInterior(playerid,0);
    PlayerInfo[playerid][pRollerLic] = 1;
    PlayerInfo[playerid][pPhoneBook] = 1;
    }
    else
    {
    rand = random(sizeof(gRandomPlayerSpawns));
    SetPlayerPos(playerid, gRandomPlayerSpawns[rand][0], gRandomPlayerSpawns[rand][1], gRandomPlayerSpawns[rand][2]); // Warp the player
    SetPlayerFacingAngle(playerid, 180.0); //normal 270.0
    SetPlayerInterior(playerid,3); //normal 15
    }
    return 1;
    }
    }
    if(PlayerInfo[playerid][pJailed] == 1)
    {
    SetPlayerInterior(playerid,3);
    SetPlayerPos(playerid,193.7812,162.1770,1003.0234);
    SetCameraBehindPlayer(playerid);
    PlayerInfo[playerid][pInt] = 3;
    TogglePlayerControllable(playerid, 1);
    SendClientMessage(playerid, COLOR_LIGHTRED, "Flüchten bringt nichts, zurück in die Zelle!");
    return 1;
    }
    return 1;
    }

    Hey Leute,


    ich weiß schon was der Error bedeutet, aber warum kommt der?
    Brauche ich ein Include oder so etwas für diese Sachen?
    Hoffe auf schnelle Hilfe,


    Narushi



    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(76) : error 017: undefined symbol "SetPlayerObjectMaterialText"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(86) : error 017: undefined symbol "SetObjectMaterialText"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(85) : warning 204: symbol is assigned a value that is never used: "MiObjeto"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(183) : error 017: undefined symbol "EditPlayerObject"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(523) : error 017: undefined symbol "SetPlayerObjectMaterialText"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(527) : warning 235: public function lacks forward declaration (symbol "OnPlayerEditObject")
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(530) : error 017: undefined symbol "EDIT_RESPONSE_FINAL"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(535) : error 017: undefined symbol "SetPlayerObjectMaterialText"
    C:\Users\Narushi\Desktop\samp\SharpadoxRL\filterscripts\toEdit.pwn(538) : error 017: undefined symbol "EDIT_RESPONSE_CANCEL"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    7 Errors.

    Vielleicht hilft dir der Fehlererklärbär :D