Jump to content

MoveObject + exemplu.


cmg4life

Recommended Posts

  • Replies 74
  • Created
  • Last Reply

Top Posters In This Topic

  • 2 months later...
  • 1 month later...
  • 2 weeks later...

Nu prea am inteles, se poate face un tutorial mai explicit? :D

#include <a_samp>

new obiect;

forward Actiunea(playerid);
public Actiunea(playerid)
{
    MoveObject(obiect, 1811.256836, -1899.554199, 12.593613, 5);
    return 1;
}

public OnGameModeInit()
{
    CreateObject(1811.245972, -1890.747925, 12.573732, 0.0000, 0.0000, 270.0000);
    return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
    if( strcmp(cmdtext, "/obiectt", true)==0)
    {
        MoveObject(obiect, 0.0, 0.0, 2.0, 5);
        SetTimerEx("Actiunea", 5 * 1000, 0, "i", playerid); //5 secunde , nu se repeta, valoarea este integer pt playerid
        return 1;
    }
    return 0;
}

asta este, iar cand intru pe server imi da crash..rezolvare?:)

Link to comment
Share on other sites

Guest Granea17

Uite cum am eu

CreateObject(638, -1998.677612, 134.806671, 27.376896, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.665161, 137.442871, 27.376896, 0.0000, 0.0000, 359.2952);
CreateObject(638, -1998.648804, 140.111816, 27.384533, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.535400, 143.593552, 27.384533, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.536133, 146.260147, 27.384533, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.432007, 151.674881, 27.384533, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.442139, 154.365295, 27.384533, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.508789, 160.073105, 27.384535, 0.0000, 0.0000, 0.0000);
CreateObject(638, -1998.487183, 162.738739, 27.384533, 0.0000, 0.0000, 0.0000);
CreateObject(970, -1978.314087, 78.351845, 27.188980, 0.0000, 0.0000, 0.0000);
CreateObject(970, -1974.191040, 78.381859, 27.163982, 0.0000, 0.0000, 0.0000);
CreateObject(970, -1965.916870, 78.486519, 27.138983, 0.0000, 0.0000, 0.0000);
CreateObject(970, -1962.597778, 78.457809, 27.138983, 0.0000, 0.0000, 0.0000);
CreateObject(970, -1960.510986, 80.507233, 27.150045, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1960.510986, 84.633469, 27.137381, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1960.485962, 88.773079, 27.138527, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1960.510986, 92.903618, 27.139858, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1960.510986, 97.045372, 27.125010, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1960.491821, 101.046402, 27.122860, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1960.483154, 105.063080, 27.138983, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2018.610352, 118.412468, 27.278440, 0.0000, 0.0000, 0.0000);
CreateObject(970, -2016.660400, 120.545616, 27.235178, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2016.622437, 124.720428, 27.238981, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2016.643677, 128.858643, 27.238981, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2016.625732, 155.207108, 27.238981, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2016.617432, 159.353668, 27.238981, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2036.356323, 183.015503, 28.387419, 0.0000, 0.0000, 0.0000);
CreateObject(970, -2032.233643, 183.014648, 28.394413, 0.0000, 0.0000, 0.0000);
CreateObject(970, -2028.109497, 183.012482, 28.387419, 0.0000, 0.0000, 0.0000);
CreateObject(970, -2023.989014, 182.993225, 28.387419, 0.0000, 0.0000, 0.0000);
CreateObject(982, -1997.238770, -47.373756, 35.003868, 0.0000, 0.0000, 0.0000);
CreateObject(982, -1996.165649, -93.278587, 35.334305, 0.0000, 0.0000, 0.0000);
CreateObject(14467, 2.600693, -1522.139160, 4.989985, 0.0000, 0.0000, 247.5000);
CreateObject(14467, 75.783577, -1535.185669, 7.051313, 0.0000, 0.0000, 90.0000);
CreateObject(2048, -1980.257568, 137.961960, 35.798599, 0.0000, 0.0000, 270.0000);
CreateObject(2047, -1980.257568, 111.838310, 36.273617, 0.0000, 0.0000, 270.0000);
CreateObject(2047, -1980.282593, 165.543549, 36.249660, 0.0000, 0.0000, 270.0000);
CreateObject(7522, -1970.389038, 93.529266, 31.203508, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.672607, 165.652756, 26.787817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.640381, 162.555161, 26.815950, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.633179, 159.445465, 26.804979, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.623291, 156.330658, 26.797598, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.633179, 153.212021, 26.793716, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.604492, 150.068390, 26.792511, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.597290, 146.955902, 26.803612, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.593018, 143.837265, 26.799797, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.585815, 140.728745, 26.807648, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.578613, 137.598053, 26.794292, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1999.596436, 134.478470, 26.754669, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2043.706177, 139.307175, 28.387419, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2043.695557, 135.171082, 28.387419, 0.0000, 0.0000, 270.0000);
CreateObject(970, -2043.702026, 131.093811, 28.387419, 0.0000, 0.0000, 270.0000);
CreateObject(3749, -1996.522583, -70.119141, 39.951889, 0.0000, 0.0000, 270.0000);
CreateObject(1267, -2033.219971, 196.009476, 45.495758, 0.0000, 0.0000, 303.7500);
CreateObject(16360, -171.909851, -1335.786133, 2.767103, 0.0000, 0.0000, 90.0000);
CreateObject(997, -1997.467773, 134.686951, 26.787817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.470459, 137.788193, 26.787817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.470459, 140.895187, 26.787817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.481689, 144.017181, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.487915, 147.132004, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.497314, 150.269608, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.499878, 153.417786, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.505981, 156.561768, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.526245, 159.663788, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.530518, 162.772385, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(997, -1997.525879, 165.880981, 26.762817, 0.0000, 0.0000, 270.0000);
CreateObject(970, -1970.062744, 78.409019, 27.159538, 0.0000, 0.0000, 0.0000);
CreateObject(979, -2025.612183, 156.968140, 28.676157, 0.0000, 0.0000, 270.0000);
CreateObject(978, -2027.551025, 156.939697, 28.676157, 0.0000, 0.0000, 270.0000);

Link to comment
Share on other sites

  • 3 months later...
  • 1 month later...
  • 1 month later...
Guest docker

[glow=red,2,300]Am verificat eu cred cas bune da nush sunt incepator iti dau sa vezi si sami spui ce am gresit te rog[/glow]

#include <a_samp>

new Gate;

public OnGameModeInit()

{

    Gate = CreateObject(976,2283.226,603.180,9.873,0.0,0.0,0.0);

    return 1;

}

public OnPlayerCommandText(playerid, cmdtext[])

{

    if( strcmp(cmdtext, "/gateop", true)==0)

    {

        MoveObject(Gate, 976,2275.426, 603.180, 9.873);

        return 1;

    }

    return 0;

}

;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D

Link to comment
Share on other sites

Guest docker

Ms mi-a mers :D si am si invatat cum sa fac :D


Daca nu te superi mai am o problema deci mai reusit am facut si doua comenzi de inchis si deschis da merg doar o singura data cand deschid sv dc   ???


Nu fa 2xpost,modifica primul post  ;)


Farse:Da comanda si ti-o rezolv  :D

Link to comment
Share on other sites

Referitor la ce a spus mai sus poti sa imi spui si mie la poarta cum fac pe doua comenzi /gateop si /gatecl?

new Gate;

public OnGameModeInit()

{

    Gate = CreateObject(976,2283.226,603.180,9.873,0.0,0.0,0.0);

    return 1;

}

public OnPlayerCommandText(playerid, cmdtext[])

{

    if( strcmp(cmdtext, "/gateop", true)==0)

    {

        MoveObject(Gate,2275.426,603.180,9.873);

        return 1;

    }

    return 0;

}

smiley-cool19.gif

Nicusor Eu   Andr3

smiley-violent096.gif

Nicusor                Eu

smiley-violent006.gif

Eu         Nicusor

Link to comment
Share on other sites

Guest farse


new Gate;

public OnGameModeInit()
{
    Gate = CreateObject(976,2283.226,603.180,9.873,0.0,0.0,0.0);
    return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
    if( strcmp(cmdtext, "/gateop", true)==0)
    {
        MoveObject(Gate,2275.426,603.180,9.473,4);//coboara z cu 0.4
        return 1;
    }
    if( strcmp(cmdtext, "/gatecl", true)==0)
    {
        MoveObject(Gate,2275.426,603.180,9.873,4);//revine la locul ei
        return 1;
    }
    return 0;
}


Link to comment
Share on other sites

am facut cum ai zis tu uite de ex asta imi da erorile

new lift;

public OnGameModeInit()

{

    lift = CreateObject(980,-1474.722,1190.261,5.738,89.381,0.859,117.425);

    return 1;

}

public OnPlayerCommandText(playerid, cmdtext[])

{

    if( strcmp(cmdtext, "/sus", true)==0)

    {

        MoveObject(lift,-1473.804,1191.710,205.413,4);

        return 1;

    }

    if( strcmp(cmdtext, "/jos", true)==0)

    {

        MoveObject(lift,-1474.722,1190.261,5.738,4);

        return 1;

    }

    return 0;

}

D:\RSS\filterscripts\g.pwn(3) : warning 235: public function lacks forward declaration (symbol "OnGameModeInit")

D:\RSS\filterscripts\g.pwn(5) : error 017: undefined symbol "CreateObject"

D:\RSS\filterscripts\g.pwn(9) : warning 235: public function lacks forward declaration (symbol "OnPlayerCommandText")

D:\RSS\filterscripts\g.pwn(11) : error 017: undefined symbol "strcmp"

D:\RSS\filterscripts\g.pwn(13) : error 017: undefined symbol "MoveObject"

D:\RSS\filterscripts\g.pwn(16) : error 017: undefined symbol "strcmp"

D:\RSS\filterscripts\g.pwn(18) : error 017: undefined symbol "MoveObject"

D:\RSS\filterscripts\g.pwn(5) : warning 204: symbol is assigned a value that is never used: "lift"

Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase

5 Errors.

smiley-cool19.gif

Nicusor Eu   Andr3

smiley-violent096.gif

Nicusor                Eu

smiley-violent006.gif

Eu         Nicusor

Link to comment
Share on other sites

  • 3 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.