[Hilfe]by gTeam fehler "multi-dimensional arrays must be fully initialized"

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
  • hey ich habe bei mein loH gf edit lvpd hinzugefügt nur ich bekomme diese fehler hier


    new JoinPed[114][1] = {
    {280}, // LSPD 0
    {281}, // LSPD 1
    {282}, // LSPD 2
    {283}, // LSPD 3
    {284}, // LSPD 4
    {285}, // LSPD 5
    {288}, // LSPD 6
    {71}, // LSPD 7
    {166}, // LSPD 8
    {148}, // LSPD 9
    {283}, // SFPD 10
    {280}, // SFPD 11
    {281}, // SFPD 12
    {148}, // SFPD 13
    {287}, // ARMY 14
    {285}, // ARMY 15
    {148}, // ARMY 16
    {70}, // MEDIC 17
    {274}, // MEDIC 18
    {276}, // MEDIC 19
    {127}, // LCN 20
    {126}, // LCN 21
    {125}, // LCN 22
    {124}, // LCN 23
    {113}, // LCN 24
    {111}, // LCN 25
    {98}, // LCN 26
    {93}, // LCN 27
    {120}, // YAKI 28
    {121}, // YAKI 29
    {122}, // YAKI 30
    {123}, // YAKI 31
    {186}, // YAKI 32
    {228}, // YAKI 33
    {169}, // YAKI 34
    {155}, // PRÄSI 35
    {193}, // PRÄSI 36
    {127}, // HITMAN 37
    {165}, // HITMAN 38
    {186}, // HITMAN 39
    {141}, // HITMAN 40
    {93}, // HITMAN 41
    {187}, // CNN 42
    {188}, // CNN 43
    {93}, // CNN 44
    {255}, // TAXI 45
    {253}, // TAXI 46
    {76}, // TAXI 47
    {59}, // FAHRSCHULE 48
    {60}, // FAHRSCHULE 49
    {150}, // FAHRSCHULE 50
    {76}, // FAHRSCHULE 51
    {100}, // BIKER 52
    {247}, // BIKER 53
    {248}, // BIKER 54
    {254}, // BIKER 55
    {248}, // BIKER 56
    {131}, // BIKER 57
    {105}, // GROVE 58
    {106}, // GROVE 59
    {107}, // GROVE 60
    {269}, // GROVE 61
    {270}, // GROVE 62
    {271}, // GROVE 63
    {191}, // GROVE 64
    {102}, // BALLAS 65
    {195}, // BALLAS 66
    {104}, // BALLAS 67
    {193}, // BALLAS 68
    {185}, // FaF 69
    {23}, // FaF 70
    {50}, // FaF 71
    {193}, // FaF 72
    {192}, // FaF 73
    {108}, // VAGOS 74
    {109}, // VAGOS 75
    {110}, // VAGOS 76
    {226}, // VAGOS 77
    {114}, // AZTECAS 78
    {115}, // AZTECAS 79
    {116}, // AZTECAS 80
    {298}, // AZTECAS 81
    {173}, // RIFA 82
    {174}, // RIFA 83
    {175}, // RIFA 84
    {214}, // RIFA 85
    {223}, // WCC 86
    {234}, // WCC 87
    {250}, // WCC 88
    {7}, // WCC 89
    {93}, // WCC 90
    {280}, // FBI 91
    {284}, // FBI 92
    {285}, // FBI 93
    {286}, // FBI 94
    {148}, // FBI 95
    {277}, // FEUERWEHR 96
    {278}, // FEUERWEHR 97
    {279}, // FEUERWEHR 98
    {272}, // RM 99
    {125}, // RM 100
    {126}, // RM 101
    {255}, // OAMT 102
    {261}, // OAMT 103
    {76}, // OAMT 104
    {206}, //BP 105
    {34}, //BP 106
    {285}, //BP 107
    {71}, //BP 108
    {280}, //LVPD
    {281} //LVPD
    };//hier meint er den fehler !?


    hier das was ich erstellt habe


    case 26: // LVPD
    {
    if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, JoinPed[109][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = JoinPed[109][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, JoinPed[110][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = JoinPed[110][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, JoinPed[111][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = JoinPed[111][0]; }
    else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, JoinPed[112][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = JoinPed[112][0]; }
    }


    so und dan wo ich es mal ohne fehler hatte kamm das immer :cursing: was voll aufregt weil pc immer down geht davon


    ^ if(gTeam[playerid] == 2 ||!IsACop(playerid))
    {
    MedicBill[playerid] = 0;
    new rand = random(sizeof(CIV));
    SendClientMessage(playerid, COLOR_LIGHTRED, "Du bist kein Polizist / FBI / Bundeswehr, du bist Zivilist !");
    PlayerInfo[playerid][pTeam] = 3;
    gTeam[playerid] = 3;
    SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
    PlayerInfo[playerid][pModel] = CIV[rand];
    SpawnPlayer(playerid);
    }


    so bitte helft mir ich bin schon an meiner grenze ich kann net mehr ;(

  • Du hast:
    new JoinPed[114][1];

    Also 114 Einträge sollten darin stehen, ich zähle jetzt aber nur 110
    -> Nicht vollständig ausgefüllt
    Also hast du zwei Möglichkeiten:
    Entweder die richtige Größe angeben:
    new JoinPed[111][1];

    oder direkt leer lassen, also
    new JoinPed[][1];

  • und der ist das richtig gescriptet ?


    case 26: //LVPD
    {
    if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, JoinPed[109][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = JoinPed[109][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, JoinPed[110][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = JoinPed[110][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, JoinPed[111][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = JoinPed[111][0]; }
    else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, JoinPed[112][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = JoinPed[112][0]; }
    }

    Einmal editiert, zuletzt von Rainer.S ()

  • hier mal der rest :D


    if(strcmp(cmd, "/invite", true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    tmp = strtok(cmdtext, idx);
    if(!strlen(tmp))
    {
    SendClientMessage(playerid, COLOR_GRAD2, "BENUTZUNG: /invite [playerid/Name]");
    return 1;
    }
    new para1;
    new ftext[24];
    para1 = ReturnUser(tmp);
    if (PlayerInfo[playerid][pLeader] >= 1)
    {
    if(IsPlayerConnected(para1))
    {
    if(para1 != INVALID_PLAYER_ID)
    {
    if (gTeam[para1]==TEAM_GREEN && PlayerInfo[para1][pMember] == 0 && PlayerInfo[para1][pFMember] == 255)
    {
    if(PlayerInfo[playerid][pLeader] == 1) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Polizei LS"; ChosenSkin[para1] = 280; SetPlayerSkin(para1, 280); }
    else if(PlayerInfo[playerid][pLeader] == 2) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Polizei SF"; ChosenSkin[para1] = 280; SetPlayerSkin(para1, 280); }
    else if(PlayerInfo[playerid][pLeader] == 3) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Armee"; ChosenSkin[para1] = 287; SetPlayerSkin(para1, 287); }
    else if(PlayerInfo[playerid][pLeader] == 4) { PlayerInfo[para1][pTeam] = 1; gTeam[para1] = 1; ftext = "Ambulance"; ChosenSkin[para1] = 70; SetPlayerSkin(para1, 70); }
    else if(PlayerInfo[playerid][pLeader] == 5) { PlayerInfo[para1][pTeam] = 5; gTeam[para1] = 5; ftext = "La Cosa Nostra"; ChosenSkin[para1] = 258; SetPlayerSkin(para1, 120); }
    else if(PlayerInfo[playerid][pLeader] == 6) { PlayerInfo[para1][pTeam] = 5; gTeam[para1] = 5; ftext = "Yakuza"; ChosenSkin[para1] = 294; SetPlayerSkin(para1, 294); }
    else if(PlayerInfo[playerid][pLeader] == 7) { PlayerInfo[para1][pTeam] = 7; gTeam[para1] = 7; ftext = "Präsident"; ChosenSkin[para1] = 164; SetPlayerSkin(para1, 164); }
    else if(PlayerInfo[playerid][pLeader] == 8) { PlayerInfo[para1][pTeam] = 8; gTeam[para1] = 8; ftext = "Hitman Agency"; ChosenSkin[para1] = 250; SetPlayerSkin(para1, 250); }
    else if(PlayerInfo[playerid][pLeader] == 9) { PlayerInfo[para1][pTeam] = 9; gTeam[para1] = 9; ftext = "CNN"; ChosenSkin[para1] = 187; SetPlayerSkin(para1, 187); }
    else if(PlayerInfo[playerid][pLeader] == 10) { PlayerInfo[para1][pTeam] = 10; gTeam[para1] = 10; ftext = "Taxigesellschaft"; ChosenSkin[para1] = 255; SetPlayerSkin(para1, 255); }
    else if(PlayerInfo[playerid][pLeader] == 11) { PlayerInfo[para1][pTeam] = 11; gTeam[para1] = 11; ftext = "Fahrlehrerorganisation"; ChosenSkin[para1] = 240; SetPlayerSkin(para1, 240); }
    else if(PlayerInfo[playerid][pLeader] == 12) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Hells Angels"; ChosenSkin[para1] = 247; SetPlayerSkin(para1, 247); }//Hells Angels
    else if(PlayerInfo[playerid][pLeader] == 13) { PlayerInfo[para1][pTeam] = 13; gTeam[para1] = 13; ftext = "Grove Street Family"; ChosenSkin[para1] = 105; SetPlayerSkin(para1, 105); }//Grove Street
    else if(PlayerInfo[playerid][pLeader] == 14) { PlayerInfo[para1][pTeam] = 14; gTeam[para1] = 14; ftext = "Ballas"; ChosenSkin[para1] = 102; SetPlayerSkin(para1, 102); }//Ballas
    else if(PlayerInfo[playerid][pLeader] == 15) { PlayerInfo[para1][pTeam] = 15; gTeam[para1] = 15; ftext = "Fast and Furios"; ChosenSkin[para1] = 185; SetPlayerSkin(para1, 185); }//2Fast2Furios
    else if(PlayerInfo[playerid][pLeader] == 16) { PlayerInfo[para1][pTeam] = 16; gTeam[para1] = 16; ftext = "L.S.Vagos"; ChosenSkin[para1] = 108; SetPlayerSkin(para1, 108); }//Los Santos Vagos
    else if(PlayerInfo[playerid][pLeader] == 17) { PlayerInfo[para1][pTeam] = 17; gTeam[para1] = 17; ftext = "V.L.Aztecas"; ChosenSkin[para1] = 114; SetPlayerSkin(para1, 114); }//Varios Los Aztecas
    else if(PlayerInfo[playerid][pLeader] == 18) { PlayerInfo[para1][pTeam] = 18; gTeam[para1] = 18; ftext = "S.F.Rifa"; ChosenSkin[para1] = 173; SetPlayerSkin(para1, 173); }//San Fiero Rifa
    else if(PlayerInfo[playerid][pLeader] == 19) { PlayerInfo[para1][pTeam] = 19; gTeam[para1] = 19; ftext = "W.C.Customs"; ChosenSkin[para1] = 234; SetPlayerSkin(para1, 234); }//West Coust Customs
    else if(PlayerInfo[playerid][pLeader] == 20) { PlayerInfo[para1][pTeam] = 20; gTeam[para1] = 20; ftext = "Terror"; ChosenSkin[para1] = 221; SetPlayerSkin(para1, 221); }
    else if(PlayerInfo[playerid][pLeader] == 21) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "FBI"; ChosenSkin[para1] = 286; SetPlayerSkin(para1, 286); }
    else if(PlayerInfo[playerid][pLeader] == 22) { PlayerInfo[para1][pTeam] = 22; gTeam[para1] = 22; ftext = "Feuerwehr"; ChosenSkin[para1] = 277; SetPlayerSkin(para1, 277); }
    else if(PlayerInfo[playerid][pLeader] == 23) { PlayerInfo[para1][pTeam] = 23; gTeam[para1] = 23; ftext = "Grundwehrdienst"; ChosenSkin[para1] = 133; SetPlayerSkin(para1, 133); }
    else if(PlayerInfo[playerid][pLeader] == 24) { PlayerInfo[para1][pTeam] = 24; gTeam[para1] = 24; ftext = "Ordnungsamt"; ChosenSkin[para1] = 255; SetPlayerSkin(para1, 255); }
    else if(PlayerInfo[playerid][pLeader] == 25) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Bundes Polizei"; ChosenSkin[para1] = 179; SetPlayerSkin(para1, 179); }
    else if(PlayerInfo[playerid][pLeader] == 26) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "LVPD"; ChosenSkin[para1] = 179; SetPlayerSkin(para1, 179); }
    else { return 1; }
    GetPlayerName(para1, giveplayer, sizeof(giveplayer));
    GetPlayerName(playerid, sendername, sizeof(sendername));
    PlayerInfo[para1][pMember] = PlayerInfo[playerid][pLeader];
    PlayerInfo[para1][pRank] = 1;
    printf("AdmCmd: %s hat %s in die Fraktion %s eingeladen.", sendername, giveplayer, ftext);
    format(string, sizeof(string), " Du wurdest in die Fraktion %s von Leader %s eingeladen.", ftext, sendername);
    SendClientMessage(para1, COLOR_LIGHTBLUE, string);
    SendClientMessage(para1, COLOR_GRAD5, " Du kannst mit /hilfe deine neuen Fraktionsbefehle betrachten");
    format(string, sizeof(string), " Du hast %s in die Fraktion %s eingeladen.", giveplayer,ftext);
    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
    SetPlayerInterior(para1,0);
    new rand = random(sizeof(gInviteSpawns));
    SetPlayerPos(para1, gInviteSpawns[rand][0], gInviteSpawns[rand][1], gInviteSpawns[rand][2]); // Warp the player
    SetPlayerFacingAngle(para1, gInviteSpawns[rand][3]);
    SetPlayerCameraPos(para1,gInviteSpawns[rand][0] + 3, gInviteSpawns[rand][1], gInviteSpawns[rand][2]);
    SetPlayerCameraLookAt(para1,gInviteSpawns[rand][0], gInviteSpawns[rand][1], gInviteSpawns[rand][2]);
    TogglePlayerControllable(para1,0);
    SelectChar[para1] = 255;
    SelectCharID[para1] = PlayerInfo[para1][pMember];
    SelectCharPlace[para1] = 1;
    PlayerInfo[para1][pModel] = ChosenSkin[para1];
    PlayerInfo[para1][pChar] = ChosenSkin[para1];
    SendClientMessage(para1, COLOR_LIGHTRED, "* Benutze 'weiter' um dir den Charakter auszusuchen den du gerne benutzen möchtest.");
    SendClientMessage(para1, COLOR_LIGHTRED, "* Wenn du den richtigen gefunden hast, gib 'Fertig' ein.");
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " Dieser Spieler ist in einer anderen Farktion oder bereits ein Fraktionsmitglied.");
    return 1;
    }
    }
    }//not connected
    }
    else
    {
    SendClientMessage(playerid, COLOR_GRAD1, " Nur der Leader kann diesen Befehl nutzen!");
    }
    }