Jump to content
  • 0

O problema.


Bogdan's

Question

Problemă întâlnită (descriere): Salut in primul rand,vreau sa fac ca un obiect sa apara cand tastez o comanda spre exemplu /gratar si sa imi apara gratarul jos,am incercat sa fac,dar nu mi-a iesit,iar prin alta comanda ex /grataroff sa se distruga gratarul(DestroyObject..
Ero(area / rile) / warning-(ul / urile): Nu am.
Liniile de cod / sursa / script-ul: [pawn] new gratar;

DestroyObject(id gratar ,x ,y ,z);[/pawn]

Doar ca nu stiu cum sa fac comenzile.Ma puteti ajuta va rog?
Imagini / Video (optional):-
Aţi încercat să rezolvaţi singur?:Da

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

Incearca asa:

 

Sus in script:

 

[pawn]new GRATAR[ MAX_PLAYERS ];[/pawn]

 

Si comenzile:

 

 

[pawn]CMD:cg( playerid, params[ ] )
{
    new Float:X, Float:Y, Float:Z, Float:rX, Float:rY, Float:rZ;
    GetPlayerPos( playerid, X, Y, Z );
    GRATAR[ playerid ] = CreatePlayerObject(playerid, 1481, X, Y, Z, rX, rY, rZ );
    return ( 1 );
}

 

CMD:dg( playerid, params[ ] )
{
    DestroyPlayerObject( playerid, GRATAR[ playerid ] );
    return ( 1 );
}[/pawn]

 

 

 

Nu am testat, ar trebui sa mearga.

35012l1.png.aee1a3398b9bd9f8eec50574d2cd

Link to comment
Share on other sites

Multumesc XEXT, am incercat sa pun si obiectul for sale dar imi apare in aer,de ce?

[pawn]new FOR[MAX_PLAYERS];
if(strcmp(cmd, "/dv", true) == 0)
{
new Float:X, Float:Y, Float:Z, Float:rX, Float:rY, Float:rZ;
GetPlayerPos( playerid, X, Y, Z );
FOR[ playerid ] = CreatePlayerObject(playerid, 19471, X, Y, Z, rX, rY, rZ );
SendClientMessage(playerid, COLOR_LIGHTBLUE, "» {FFFFFF}Ai asamblat cu succes un semn de vanzare.Scrie (/sdv)anzare pentru a scoate semnul.");
return ( 1 );
}
if(strcmp(cmd, "/sdv", true) == 0)
{
DestroyPlayerObject( playerid, FOR[ playerid ] );
SendClientMessage(playerid, COLOR_LIGHTBLUE, "» {FFFFFF}Ai scos cu succes semnul de vanzare.");
return ( 1 );
}[/pawn]

Edited by Bogdan's
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • 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.