Register / Login Passwort Problem

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
  • OnPlayerSpawn:


    public OnPlayerSpawn(playerid)
    {
    new String[128],Dm[9];
    for(new i = 0; MAX_PLAYERS > i; i++){
    for(new ii = 0; 9 > ii; ii++){
    if(DM[i][ii] == 1){
    Dm[ii]++;
    }
    }
    }
    SetPlayerSkin(playerid,PlayerInfo[playerid][pSkin]);
    format(String,sizeof(String),"/Deagle: %d - /Dm: %d - /1o1: %d - /Fdm: %d - /Sniper: %d - /Teamdm: %d - /Insel: %d - Kein Modus: %d",Dm[0],Dm[1],Dm[2],Dm[3],Dm[4],Dm[5],Dm[6],Dm[8]);
    TextDrawSetString(Textdraw[3],String);
    if(DM[playerid][8] == 1){
    SetPlayerInterior(playerid,0);
    SetPlayerVirtualWorld(playerid,0);
    }else if(DM[playerid][0] == 1){
    new rand = random(4);
    SetPlayerInterior(playerid,18);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }else if(DM[playerid][1] == 1){
    new rand = 4+random(4);
    SetPlayerInterior(playerid,0);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    GivePlayerWeapon(playerid,34,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }else if(DM[playerid][2] == 1){
    SetPlayerInterior(playerid,7);
    GivePlayerWeapon(playerid,24,1337);
    SetPlayerPos(playerid,298.507934,-141.647048,1004.054748);
    SetPlayerFacingAngle(playerid,0);
    for(new i = 0; 4 > i;i++){
    if(one[playerid][i] == 1){
    SetPlayerVirtualWorld(playerid,i+1);
    }
    }
    }else if(DM[playerid][5] != 0){
    new rand = 12+random(6);
    SetPlayerInterior(playerid,3);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }else if(DM[playerid][4] == 1){
    new rand = 8+random(4);
    SetPlayerInterior(playerid,0);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,34,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }else if(DM[playerid][6] == 1){
    new rand = 18+random(4);
    SetPlayerInterior(playerid,0);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }else if(DM[playerid][3] == 1){
    new rand = 22+random(4);
    SetPlayerInterior(playerid,18);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    GivePlayerWeapon(playerid,33,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    new ppname[MAX_PLAYER_NAME],file[250],clanname3d[50];
    GetPlayerName(playerid,ppname,sizeof(ppname));
    format(file,sizeof(file),"/Clans/%s.sav",(ppname));


    if(dini_Exists(file))
    {
    format(clanname[playerid], 32, dini_Get(file,"Clan"));
    clanstate[playerid] = dini_Int(file,"Rang");


    if(labels[playerid] != Text3D:-1) Delete3DTextLabel(labels[playerid]);
    labels[playerid] = Text3D:-1;


    if(clanstate[playerid] == 3)
    {
    format(clanname3d,sizeof(clanname3d),"%s{FF0000} Leader {EEEEEE}",clanname[playerid]);
    labels[playerid] = Create3DTextLabel(clanname3d,-1,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(labels[playerid], playerid, 0.0, 0.0, 0.5);
    }
    else if(clanstate[playerid] == 1)
    {
    format(clanname3d,sizeof(clanname3d),"%s{FF0000} Member {EEEEEE}",clanname[playerid]);
    }
    labels[playerid] = Create3DTextLabel(clanname3d,-1,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(labels[playerid], playerid, 0.0, 0.0, 0.5);
    }


    return 1;
    }


    Jeffry hab doch noch mal meine Varriante genommen was die DM Arenen betreffen :D mit dem anderen kam ich iwie nicht ganz klar :o Jedenfalls das OnPlayerSpawn

  • Debugge die beiden Callbacks bitte mal so:
    public OnPlayerRequestSpawn(playerid)
    {
    printf("OnPlayerRequestSpawn (%d)", SkinSelection[playerid]);
    if(SkinSelection[playerid] != 0)
    {
    printf("Skin: %d", GetPlayerSkin(playerid));
    PlayerInfo[playerid][pSkin] = GetPlayerSkin(playerid);
    }
    return 1;
    }


    public OnPlayerSpawn(playerid)
    {
    printf("OnPlayerSpawn");
    new String[128],Dm[9];
    for(new i = 0; MAX_PLAYERS > i; i++)
    {
    for(new ii = 0; 9 > ii; ii++)
    {
    if(DM[i][ii] == 1)
    {
    Dm[ii]++;
    }
    }
    }
    printf("Setze Skin: %d", PlayerInfo[playerid][pSkin]);
    SetPlayerSkin(playerid,PlayerInfo[playerid][pSkin]);
    format(String,sizeof(String),"/Deagle: %d - /Dm: %d - /1o1: %d - /Fdm: %d - /Sniper: %d - /Teamdm: %d - /Insel: %d - Kein Modus: %d",Dm[0],Dm[1],Dm[2],Dm[3],Dm[4],Dm[5],Dm[6],Dm[8]);
    TextDrawSetString(Textdraw[3],String);
    if(DM[playerid][8] == 1)
    {
    SetPlayerInterior(playerid,0);
    SetPlayerVirtualWorld(playerid,0);
    }
    else if(DM[playerid][0] == 1)
    {
    new rand = random(4);
    SetPlayerInterior(playerid,18);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    else if(DM[playerid][1] == 1)
    {
    new rand = 4+random(4);
    SetPlayerInterior(playerid,0);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    GivePlayerWeapon(playerid,34,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    else if(DM[playerid][2] == 1)
    {
    SetPlayerInterior(playerid,7);
    GivePlayerWeapon(playerid,24,1337);
    SetPlayerPos(playerid,298.507934,-141.647048,1004.054748);
    SetPlayerFacingAngle(playerid,0);
    for(new i = 0; 4 > i;i++)
    {
    if(one[playerid][i] == 1)
    {
    SetPlayerVirtualWorld(playerid,i+1);
    }
    }
    }
    else if(DM[playerid][5] != 0)
    {
    new rand = 12+random(6);
    SetPlayerInterior(playerid,3);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    else if(DM[playerid][4] == 1)
    {
    new rand = 8+random(4);
    SetPlayerInterior(playerid,0);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,34,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    else if(DM[playerid][6] == 1)
    {
    new rand = 18+random(4);
    SetPlayerInterior(playerid,0);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    else if(DM[playerid][3] == 1)
    {
    new rand = 22+random(4);
    SetPlayerInterior(playerid,18);
    SetPlayerHealth(playerid,100);
    SetPlayerArmour(playerid,100);
    GivePlayerWeapon(playerid,24,1337);
    GivePlayerWeapon(playerid,25,1337);
    GivePlayerWeapon(playerid,33,1337);
    SetPlayerPos(playerid,RandomSpawn[rand][rX],RandomSpawn[rand][rY],RandomSpawn[rand][rZ]);
    SetPlayerFacingAngle(playerid,RandomSpawn[rand][rA]);
    }
    new ppname[MAX_PLAYER_NAME],file[250],clanname3d[50];
    GetPlayerName(playerid,ppname,sizeof(ppname));
    format(file,sizeof(file),"/Clans/%s.sav",(ppname));

    if(dini_Exists(file))
    {
    format(clanname[playerid], 32, dini_Get(file,"Clan"));
    clanstate[playerid] = dini_Int(file,"Rang");

    if(labels[playerid] != Text3D:-1) Delete3DTextLabel(labels[playerid]);
    labels[playerid] = Text3D:-1;

    if(clanstate[playerid] == 3)
    {
    format(clanname3d,sizeof(clanname3d),"%s{FF0000} Leader {EEEEEE}",clanname[playerid]);
    labels[playerid] = Create3DTextLabel(clanname3d,-1,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(labels[playerid], playerid, 0.0, 0.0, 0.5);
    }
    else if(clanstate[playerid] == 1)
    {
    format(clanname3d,sizeof(clanname3d),"%s{FF0000} Member {EEEEEE}",clanname[playerid]);
    }
    labels[playerid] = Create3DTextLabel(clanname3d,-1,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(labels[playerid], playerid, 0.0, 0.0, 0.5);
    }

    return 1;
    }


    Dann poste was im Server Log steht.

  • bekomme leider den CJ Skin Trotz Skin ID 1 ,


    Serverlog :



    ----------
    Loaded log file: "server_log.txt".
    ----------


    SA-MP Dedicated Server
    ----------------------
    v0.3z, (C)2005-2014 SA-MP Team


    [20:45:35] filterscripts = "" (string)
    [20:45:35]
    [20:45:35] Server Plugins
    [20:45:35] --------------
    [20:45:35] Loaded 0 plugins.


    [20:45:35]
    [20:45:35] Ban list
    [20:45:35] --------
    [20:45:35] Loaded: samp.ban
    [20:45:35]
    [20:45:35]
    [20:45:35] Filterscripts
    [20:45:35] ---------------
    [20:45:35] Loaded 0 filterscripts.


    [20:45:35]
    ----------------------------------
    [20:45:35] Free Deathmatch
    [20:45:35] ----------------------------------


    [20:45:35] Number of vehicle models: 3
    [20:46:18] Incoming connection: 127.0.0.1:62391
    [20:46:18] [join] Testaccount. has joined the server (0:127.0.0.1)
    [20:46:36] Setze Passwort zu: 'testpasswort'
    [20:46:38] OnPlayerRequestSpawn (0)
    [20:46:38] OnPlayerSpawn
    [20:46:38] Setze Skin: 0
    [20:46:40] <IPLocator Error> HTTP response code: 3

  • SkinSelection[playerid]
    ist 0 (siehe erster Print).


    Daher wird kein Skin gespeichert.



    Wenn du nicht weißt wo du das auf 1 setzen musst, schreibe es so:
    public OnPlayerRequestSpawn(playerid)
    {
    printf("Skin: %d", GetPlayerSkin(playerid));
    PlayerInfo[playerid][pSkin] = GetPlayerSkin(playerid);
    return 1;
    }

  • Danke ,


    hatte im Scripte unter OnPlayerRequestSpawn noch was anderes stehen hab da vorhin iwie gefailt hab das aber jetzt richtig gemacht und Funktionier ;)
    was ich nicht verstehe vor 2 tagen gingen noch die dm Arenen und jetzt ka buggen die rum aber krieg ich allein hin :p