Help with CreateObject
#1

I want a script as I have failed when trying already 10 times..

Basically, there's a
Код:
CreateObject(3400,-764.24603271,1554.28637695,25.98982620,0.00000000,0.00000000,90.00000000);
Then I want it to be removed when /doom is used and then this command goes into play (replaces prev. object)
Код:
CreateObject(3401,-764.24603271,1554.28637695,25.98982620,0.00000000,0.00000000,90.00000000);
Then you do /doom off and it goes back to
Код:
CreateObject(3400,-764.24603271,1554.28637695,25.98982620,0.00000000,0.00000000,90.00000000);
Reply
#2

Example:
pawn Код:
new a;

CMD:doom(playerid,params[])
{
    if(sscanf(params,"S(on) ",params) return SendClientMessage(playerid,color,"Useage: blablabla");
    else
    {
        if(!strcmp(params,"on"))
        {
            DestroyObject(a);
            a = CreateObject(....)
            return 1;
        }
        if(!strcmp(params,"off")) return DestroyObject(a);
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)