Beiträge von UnLiMiTeD

    Hallo,
    Wollte mal ein Menu machen.


    Hier:
    #include <a_samp>


    #if defined FILTERSCRIPT
    #define 0xFF0000FF 0xFF0000FF


    new Menu:Info;



    public OnFilterScriptInit()
    {
    Info = CreateMenu("MenuTest",2,200.0,100.0,150.0,150.0);
    AddMenuItem(Info,0,"1");
    AddMenuItem(Info,0,"2");
    return 1;
    }




    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("/Menu", cmdtext, true, 10) == 0)
    {
    ShowMenuForPlayer(Info,playerid);
    return 1;
    }
    return 0;
    }



    public OnPlayerSelectedMenuRow(playerid, row)
    {
    new Menu:CurrentMenu = GetPlayerMenu(playerid);
    if(CurrentMenu == Info)
    {
    switch(row)
    {
    case 0:
    {
    GivePlayerMoney(playerid,-500);
    GivePlayerWeapon(playerid,32,500);
    SendClientMessage(playerid,0xFF0000FF,"Du hast dir eine Tec-9 für 500 Dollar gekauft");
    }
    case 1:
    {
    GivePlayerMoney(playerid,-1000);
    GivePlayerWeapon(playerid,29,500);
    SendClientMessage(playerid,0xFF0000FF,"Du hast dir eine kp Waffe gekaufen für 1000 Dollar");
    }
    }
    }
    return 1;
    }



    Errors:


    D:\Users\UnLiMiTeD\Desktop\SoD\Menu.pwn(84) : error 017: undefined symbol "Info"
    D:\Users\UnLiMiTeD\Desktop\SoD\Menu.pwn(16) : error 017: undefined symbol "Info"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    2 Errors.



    Das Menu Script is als Filterscript

    Ja,
    Wie schon in der Überschrift gesagt wenn wir auf unserem Godfather Gamemode in der Bank /withdraw eingeben geht der Server down -/ aus.


    Hier mal der CMD:

    if(strcmp(cmd, "/withdraw", true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    if(PlayerToPoint(7,playerid,1437.4437,-996.2574,1639.7843))
    {
    tmp = strtok(cmdtext, idx);
    if(!strlen(tmp))
    {
    SendClientMessage(playerid, COLOR_GRAD2, "Benutze: /withdraw [amount]");
    format(string, sizeof(string), " Du hast $%d auf dem Konto.", PlayerInfo[playerid][pAccount]);
    SendClientMessage(playerid, COLOR_GRAD3, string);
    return 1;
    }
    new cashdeposit = strval(tmp);
    if(!strlen(tmp))
    {
    SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /withdraw [amount]");
    format(string, sizeof(string), " Du hast $%d auf dem Konto.", PlayerInfo[playerid][pAccount]);
    SendClientMessage(playerid, COLOR_GRAD3, string);
    return 1;
    }
    if (cashdeposit > PlayerInfo[playerid][pAccount] || cashdeposit < 1)
    {
    SendClientMessage(playerid, COLOR_GRAD2, " Du hast nicht soviel !");
    return 1;
    }
    ConsumingMoney[playerid] = 1;
    sdx_GivePlayerMoney(playerid,cashdeposit);
    PlayerInfo[playerid][pAccount]=PlayerInfo[playerid][pAccount]-cashdeposit;
    format(string, sizeof(string), " Du hast $%d vom Konto geholt. Gesamt: $%d ", cashdeposit,PlayerInfo[playerid][pAccount]);
    SendClientMessage(playerid, COLOR_YELLOW, string);
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "%s hat $%d von seinem Konto abgebucht", name,cashdeposit);
    PayLog(string);
    return 1;
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " Du bist nicht in der Bank oder an einem Bankomat !");
    return 1;
    }
    }
    return 1;
    }

    Leute,
    Ich habe die LS Bank von InternetInk in meinen gm gebaut und wenn ich /rein mache spawnt er in der Luft wisst ihr warum??
    Objekte sind drinne:


    siehe:


    CreateObject(14789, 1424.690308, -1004.066162, 1643.018677, 0.0000, 0.0000, 90.0000);
    CreateObject(2774, 1433.026245, -1004.643921, 1635.819824, 0.0000, 0.0000, 0.0000);
    CreateObject(2774, 1429.296997, -1004.618652, 1641.281128, 0.0000, 0.0000, 0.0000);
    CreateObject(2774, 1440.957031, -979.682068, 1640.297729, 0.0000, 0.0000, 0.0000);
    CreateObject(2774, 1429.337158, -979.545288, 1639.723389, 0.0000, 0.0000, 0.0000);
    CreateObject(2774, 1449.314087, -984.505005, 1648.023193, 0.0000, 0.0000, 0.0000);
    CreateObject(2774, 1413.914063, -984.515381, 1643.073486, 0.0000, 0.0000, 0.0000);
    CreateObject(1886, 1448.510132, -1003.642944, 1647.093994, 19.7670, 0.0000, 223.3584);
    CreateObject(1886, 1414.706543, -980.604431, 1647.061646, 19.7670, 0.0000, 43.3584);
    CreateObject(2774, 1430.416870, -999.017273, 1638.722412, 0.0000, 269.7592, 0.0000);
    CreateObject(2774, 1408.149292, -998.996826, 1638.722412, 0.0000, 269.7592, 180.0000);
    CreateObject(2774, 1443.577271, -986.634644, 1638.723389, 0.0000, 269.7592, 270.0000);
    CreateObject(2774, 1443.604492, -998.998169, 1647.797485, 0.0000, 0.0000, 0.0000);
    CreateObject(11359, 1414.356201, -988.985352, 1639.795898, 0.0000, 0.0000, 90.0000);
    CreateObject(2774, 1413.927368, -986.011719, 1643.046997, 0.0000, 0.0000, 270.0000);
    CreateObject(2774, 1413.763672, -992.085388, 1643.673340, 0.0000, 0.0000, 0.0000);
    CreateObject(626, 1427.554565, -997.322998, 1640.766479, 0.0000, 0.0000, 135.0000);
    CreateObject(626, 1427.488281, -990.752502, 1640.841553, 0.0000, 0.0000, 135.0000);
    CreateObject(2773, 1427.756714, -995.781189, 1639.310181, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1427.694946, -992.841431, 1639.310181, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1427.596924, -989.128601, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1429.863159, -982.927368, 1639.310181, 0.0000, 0.0000, 90.0000);
    CreateObject(626, 1427.665283, -983.128601, 1640.841553, 0.0000, 0.0000, 236.2500);
    CreateObject(2773, 1432.755859, -982.990784, 1639.310181, 0.0000, 0.0000, 90.0000);
    CreateObject(626, 1434.648315, -983.188904, 1640.841553, 0.0000, 0.0000, 236.2500);
    CreateObject(2773, 1437.091431, -983.054993, 1639.310181, 0.0000, 0.0000, 90.0000);
    CreateObject(2773, 1440.040283, -983.012756, 1639.310181, 0.0000, 0.0000, 90.0000);
    CreateObject(3462, 1448.466919, -993.014465, 1640.297974, 0.0000, 0.0000, 0.0000);
    CreateObject(3462, 1448.512085, -982.992615, 1640.181519, 0.0000, 0.0000, 0.0000);
    CreateObject(626, 1441.636230, -997.047729, 1640.741455, 0.0000, 0.0000, 146.2500);
    CreateObject(14632, 1443.648682, -995.934631, 1638.667725, 0.0000, 0.0000, 90.0000);
    CreateObject(14632, 1432.156372, -1018.015259, 1639.988159, 0.0000, 0.0000, 270.0000);
    CreateObject(1514, 1432.294922, -998.852478, 1639.740112, 0.0000, 0.0000, 180.0000);
    CreateObject(1514, 1438.352539, -998.846741, 1639.815674, 0.0000, 0.0000, 180.0000);
    CreateObject(2773, 1435.183838, -996.759277, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1435.152466, -993.932556, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1439.338623, -996.658691, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1439.288940, -994.000671, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(1723, 1426.280151, -994.863586, 1638.707275, 0.0000, 0.0000, 270.0000);
    CreateObject(1723, 1426.244629, -991.150452, 1638.732300, 0.0000, 0.0000, 270.0000);
    CreateObject(1723, 1422.277466, -996.935059, 1638.682251, 0.0000, 0.0000, 90.0000);
    CreateObject(1723, 1422.279297, -993.210022, 1638.657227, 0.0000, 0.0000, 90.0000);
    CreateObject(2637, 1424.232422, -992.173584, 1638.838745, 0.0000, 0.0000, 270.0000);
    CreateObject(2637, 1424.228516, -995.704163, 1638.838745, 0.0000, 0.0000, 270.0000);
    CreateObject(3657, 1432.633301, -987.739014, 1639.202393, 0.0000, 0.0000, 0.0000);
    CreateObject(3657, 1432.631104, -986.977234, 1639.202393, 0.0000, 0.0000, 180.0000);
    CreateObject(3657, 1438.111572, -986.977539, 1639.202393, 0.0000, 0.0000, 180.0000);
    CreateObject(3657, 1438.086304, -987.730713, 1639.227417, 0.0000, 0.0000, 0.0000);
    CreateObject(2961, 1439.028320, -999.826660, 1639.211304, 0.0000, 0.0000, 0.0000);
    CreateObject(2961, 1433.505615, -999.827637, 1639.301392, 0.0000, 0.0000, 0.0000);
    CreateObject(2946, 1414.355225, -990.513489, 1638.755615, 0.0000, 0.0000, 0.0000);
    CreateObject(2946, 1414.380249, -987.392517, 1638.755005, 0.0000, 0.0000, 180.0000);
    CreateObject(2963, 1424.165283, -1004.815674, 1640.781128, 0.0000, 0.0000, 270.0000);
    CreateObject(2963, 1426.806763, -1004.832520, 1640.826904, 0.0000, 0.0000, 90.0000);
    CreateObject(1886, 1414.730591, -993.523010, 1646.908569, 17.1887, 0.0000, 67.5000);
    CreateObject(2773, 1431.414551, -996.845825, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(2773, 1431.473389, -994.017090, 1639.301514, 0.0000, 0.0000, 0.0000);
    CreateObject(632, 1434.735352, -987.757507, 1639.131226, 0.0000, 0.0000, 213.7500);
    CreateObject(2942, 1417.713623, -980.475159, 1639.363525, 0.0000, 0.0000, 0.0000);
    CreateObject(1216, 1443.281372, -989.311279, 1639.387817, 0.0000, 0.0000, 270.0000);
    CreateObject(2942, 1421.217163, -980.448914, 1639.385498, 0.0000, 0.0000, 0.0000);
    CreateObject(2942, 1424.630493, -980.526672, 1639.371460, 0.0000, 0.0000, 0.0000);
    CreateObject(1216, 1443.277832, -991.424866, 1639.424194, 0.0000, 0.0000, 270.0000);
    CreateObject(1216, 1443.251221, -987.278198, 1639.376221, 0.0000, 0.0000, 270.0000);
    CreateObject(1216, 1443.259766, -985.484985, 1639.376221, 0.0000, 0.0000, 270.0000);
    CreateObject(2773, 1441.228638, -993.042969, 1639.301514, 0.0000, 0.0000, 270.0000);
    CreateObject(2824, 1424.297241, -992.054932, 1639.247681, 0.0000, 0.0000, 78.7500);


    hier der /Rein Command:


    if(strcmp("/Rein", cmdtext, true , 10) == 0)
    {
    if(PlayerToPoint(4.0, playerid,560.0772,-1506.7532,14.5435))//Bank
    {
    SetPlayerPos(playerid,1415.951171,-988.971191,1639.980224);
    SetPlayerInterior(playerid,0);
    }
    return 1;
    }


    Die Coords zum reingehen sind so:
    1415.951171,-988.971191,1639.980224

    Machs ma so:


    if (strcmp(cmd, "/marker", true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    if(m[playerid] == 0)
    {
    Checkpoint1 = SetPlayerCheckpoint(playerid, 2237.41, -2492.02, 13.54, 7.5);
    SendClientMessage(playerid,COLOR_RED, "* Fliege zum Roten Marker!");
    }
    return 1;
    }


    dann erstellste eine neue Public wenn du sie nicht schon hast.


    public OnPlayerEnterCheckpoint(playerid)
    {
    Checkpoint1 = DisablePlayerCheckpoint(playerid);
    return 1;
    }

    hast du noch andere Arten von:


    new Float:gInviteSpawns[1][4] = {
    {-1976.5912,166.1818,36.9623,272.6393}
    };


    im Gamemode??
    Wenn nicht dann ist das auch falsch

    kannst aber auch so machen das nur der Checkpoint weg ist falls du 2 hast.


    oben im gm einfach einfügen:
    new Checkpoint1;


    dann machste den command so wie neo aber so:


    if (strcmp(cmd, "/marker", true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    if(m[playerid] == 0)
    {
    Checkpoint1 = SetPlayerCheckpoint(playerid, 2237.41, -2492.02, 13.54, 7.5);
    SendClientMessage(playerid,COLOR_RED, "* Fliege zum Roten Marker!");
    }
    else
    {
    Checkpoint1 = DisablePlayerCheckPoint(playerid);
    }
    }
    }

    ist bestimmt /Invite


    such mal im gm nach:


    gInviteSpawn


    Und dahinter die Fraktions id in []


    dann kannste den Spawn glaube ich entscheiden.
    Weiss es aber nicht da ich kein GF Nehme