Brauche Hilfe!!!!!

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
  • Hallo ich habe mir eine schranke gebaut nur irgendwie geht die nicht auf
    if (strcmp(cmdtext, "/aa3", true) == 0){
    MoveObject(g_gate,-2671.138184, 1269.625854, 55.488937, 0.0000, 359.1406, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/zz3", true) == 0){
    MoveObject(g_gate,-2671.170166, 1269.633179, 55.488937, 0.0000, 89.3814, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;


    Wo liegt das der feler
    (das ist ein script auschnitt)

  • Gibt es irgendwelche Errors oder Warnings?
    Ein Fehler seh ich jetzt gerade nicht..ist es denn auch in OnPlayerCommandText?



    public OnPlayerCommandText(playerid,cmdtext[])
    {
    if (strcmp(cmdtext, "/aa3", true) == 0)
    {
    MoveObject(g_gate,-2671.138184, 1269.625854, 55.488937, 0.0000, 359.1406, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }


    if (strcmp(cmdtext, "/zz3", true) == 0)
    {
    MoveObject(g_gate,-2671.170166, 1269.633179, 55.488937, 0.0000, 89.3814, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    return 0;
    }


    Das müsste auf jedenfall gehen.
    VIelleicht hast du auch die Koordinaten vertauscht?

  • Das ist jetzt mal der ganze script:
    #include <a_samp>


    #pragma tabsize 0
    #define COLOR_YELLOW 0xFFFF00AA
    #define FILTERSCRIPT
    #if defined FILTERSCRIPT
    new y_gate;
    new c_gate;
    new a_gate;
    new b_gate;
    new d_gate;
    new e_gate;
    new f_gate;
    new g_gate;



    public OnFilterScriptInit()
    {
    y_gate = CreateObject(980, -550.156494, 1999.103149, 61.960892, 0.0000, 0.0000, 45.0000);
    CreateObject(3749, -863.475891, 2009.446655, 65.045914, 0.0000, 0.0000, 303.7500);
    CreateObject(3749, -549.978882, 1999.089355, 65.045914, 0.0000, 0.0000, 45.0000);
    c_gate = CreateObject(980,-863.796448, 2009.255127, 61.960892, 0.0000, 0.0000, 303.7500);
    CreateObject(980, -854.018311, 1997.157471, 61.960892, 0.0000, 0.0000, 123.7499);
    CreateObject(980, -854.075439, 1997.161133, 67.292198, 0.0000, 0.0000, 123.7500);
    CreateObject(980, -539.185791, 2010.186035, 61.960892, 0.0000, 0.0000, 225.0000);
    CreateObject(980, -539.238953, 2010.191162, 67.428047, 0.0000, 0.0000, 225.0000);
    CreateObject(980, -939.877319, 2031.792847, 62.712303, 0.0000, 0.0000, 45.0000);
    CreateObject(980, -931.791626, 2039.957886, 63.819122, 0.0000, 0.0000, 225.0000);
    CreateObject(980, -923.883057, 2039.979370, 62.687454, 0.0000, 0.0000, 315.0000);
    CreateObject(980, -915.795410, 2031.915649, 62.687454, 0.0000, 0.0000, 315.0000);
    CreateObject(980, -907.910583, 2023.661743, 62.844185, 0.0000, 0.0000, 315.0000);
    CreateObject(980, -900.463562, 2014.896973, 62.786098, 0.0000, 0.0000, 303.7500);
    CreateObject(980, -893.485718, 2006.185547, 62.823792, 0.0000, 0.0000, 315.0000);
    a_gate = CreateObject(980, -893.222351, 1998.022095, 62.687454, 0.0000, 0.0000, 45.0000);
    CreateObject(980, -901.360168, 1989.910522, 62.687454, 0.0000, 0.0000, 45.0000);
    CreateObject(980, -911.020996, 1986.415894, 63.052681, 0.0000, 0.0000, 0.0000);


    CreateObject(980, -1099.078857, 2222.057617, 88.227188, 0.0000, 0.0000, 270.0000);
    CreateObject(980, -1098.564575, 2233.694824, 90.216820, 0.0000, 0.0000, 270.0000);
    CreateObject(980, -1094.853394, 2243.963135, 91.762100, 0.0000, 0.0000, 56.2500);
    CreateObject(980, -1088.306030, 2253.117432, 90.390366, 0.0000, 0.0000, 56.2500);
    b_gate = CreateObject(980, -1080.101440, 2258.173096, 89.430054, 0.0000, 0.0000, 0.0000);
    CreateObject(980, -1069.073486, 2255.963379, 89.243546, 0.0000, 0.0000, 337.5000);
    CreateObject(980, -1058.426636, 2251.028320, 88.260551, 0.0000, 0.0000, 326.2500);
    CreateObject(980, -1049.408325, 2243.836914, 87.692635, 0.0000, 0.0000, 315.0000);
    CreateObject(980, -1042.900269, 2237.630615, 87.240547, 0.0000, 0.0000, 315.0000);
    CreateObject(980, -1099.033447, 2216.408447, 88.231529, 0.0000, 0.0000, 90.0000);
    CreateObject(7916, -949.282349, 2051.342285, 68.691193, 0.0000, 0.0000, 112.5000);
    CreateObject(1225, -927.125610, 2042.730225, 60.319817, 0.0000, 0.0000, 0.0000);
    CreateObject(1225, -925.916199, 2042.693726, 60.319817, 0.0000, 0.0000, 0.0000);
    CreateObject(1225, -926.555298, 2041.967896, 60.319817, 0.0000, 0.0000, 0.0000);
    CreateObject(1225, -927.405762, 2041.929443, 60.319817, 0.0000, 0.0000, 0.0000);
    CreateObject(1225, -925.547180, 2041.786499, 60.319817, 0.0000, 0.0000, 0.0000);
    CreateObject(1225, -928.075684, 2041.478760, 60.319817, 0.0000, 0.0000, 0.0000);
    CreateObject(1225, -926.997009, 2041.193359, 60.319817, 0.0000, 0.0000, 270.0000);
    CreateObject(1225, -926.094543, 2041.130981, 60.319817, 0.0000, 0.0000, 326.2500);
    CreateObject(966, -2671.169434, 1269.650635, 54.429688, 0.0000, 0.0000, 180.0000);
    CreateObject(966, -2673.748535, 1269.925049, 54.429688, 0.0000, 0.0000, 0.0000);
    CreateObject(966, -2689.453613, 1269.718628, 54.945576, 0.0000, 0.0000, 180.0000);
    CreateObject(966, -2691.490967, 1269.546021, 54.945576, 0.0000, 0.0000, 0.0000);
    d_gate = CreateObject(968, -2691.313232, 1269.463745, 56.004826, 0.0000, 271.4781, 0.0000);
    e_gate = CreateObject(968, -2689.648193, 1269.701294, 56.004826, 0.0000, 89.3814, 0.0000);
    f_gate = CreateObject(968, -2673.616943, 1269.808350, 55.616131, 0.0000, 266.3215, 358.2811);
    g_gate = CreateObject(968, -2671.170166, 1269.633179, 55.488937, 0.0000, 89.3814, 0.0000);




    print("\n--------------------------------------");
    print(" Reallifescript by [AM]_Alex");
    print("--------------------------------------\n");
    return 1;
    }


    public OnFilterScriptExit()
    {
    return 1;
    }


    #else
    #endif


    public OnGameModeInit()
    {
    // Don't use these lines if it's a filterscript
    SetGameModeText("German Realive by AM Clan");
    AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
    return 1;
    }


    public OnGameModeExit()
    {
    return 1;
    }


    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 OnPlayerRequestSpawn(playerid)
    {
    return 1;
    }


    public OnPlayerConnect(playerid)
    {
    return 1;
    }


    public OnPlayerDisconnect(playerid, reason)
    {
    return 1;
    }


    public OnPlayerSpawn(playerid)
    {
    return 1;
    }


    public OnPlayerDeath(playerid, killerid, reason)
    {
    return 1;
    }


    public OnVehicleSpawn(vehicleid)
    {
    return 1;
    }


    public OnVehicleDeath(vehicleid, killerid)
    {
    return 1;
    }


    public OnPlayerText(playerid, text[])
    {
    return 1;
    }


    public OnPlayerPrivmsg(playerid, recieverid, text[])
    {
    return 1;
    }


    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp(cmdtext, "/wacheauf", true) == 0){
    MoveObject(y_gate,-550.156494, 1999.103149, 52.960892, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/wachezu", true) == 0){
    MoveObject(y_gate,-550.156494, 1999.103149, 61.960892, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/wacheauf1", true) == 0){
    MoveObject(c_gate,-863.796448, 2009.255127, 52.960892, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/wachezu1", true) == 0){
    MoveObject(c_gate,-863.796448, 2009.255127, 61.960892, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/parkingauf", true) == 0){
    MoveObject(a_gate,-893.222351, 1998.022095, 52.687454, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/parkingzu", true) == 0){
    MoveObject(a_gate,-893.222351, 1998.022095, 62.687454, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/parkingauf1", true) == 0){
    MoveObject(b_gate,-1080.101440, 2258.173096, 80.430054, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/parkingzu1", true) == 0){
    MoveObject(b_gate,-1080.101440, 2258.173096, 89.430054, 5.00);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/aa", true) == 0){
    MoveObject(d_gate,-2691.547607, 1269.538696, 56.004826, 0.0000, 0.0000, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/zz", true) == 0){
    MoveObject(d_gate,-2691.313232, 1269.463745, 56.004826, 0.0000, 271.4781, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/aa1", true) == 0){
    MoveObject(e_gate,-2689.424072, 1269.712524, 56.004826, 0.0000, 0.0000, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/zz1", true) == 0){
    MoveObject(e_gate,-2689.648193, 1269.701294, 56.004826, 0.0000, 89.3814, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/aa2", true) == 0){
    MoveObject(f_gate,-2673.771973, 1269.900146, 55.488937, 0.0000, 0.0000, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/zz2", true) == 0){
    MoveObject(f_gate,-2673.616943, 1269.808350, 55.616131, 0.0000, 266.3215, 358.2811);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    if (strcmp(cmdtext, "/aa3", true) == 0){
    MoveObject(g_gate,-2671.138184, 1269.625854, 55.488937, 0.0000, 359.1406, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Sehr stark bewachtes Gelände!");
    return 1;
    }
    if (strcmp(cmdtext, "/zz3", true) == 0){
    MoveObject(g_gate,-2671.170166, 1269.633179, 55.488937, 0.0000, 89.3814, 0.0000);
    SendClientMessage(playerid, COLOR_YELLOW,"ACHTUNG: Haste schiss?");
    return 1;
    }
    }