Help! The gate not work -
martini002 - 05.04.2011
Dear All
for the moment, the gm compile all ok
so when i write the command not open de gate :S
i appreciate your help
that say, The Gate is opened.Welcome! but not move the object
Code:
psur = CreateDynamicObject(971,-982.02215576,490.67080688,3.03113890,0.00000000,0.00000000,46.00000000); //puerta sur
CMD:ps(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 4 || IsPlayerAdmin(playerid)) {
MoveObject(psur, -982.02215576,490.67080688,-1.803113890, 3);
SendClientMessage(playerid, 0xFFFF00AA,"The Gate is opened.Welcome!");
return 1;
} else return SendClientMessage(playerid,COLOR_RED,"ERROR: You are not a high enough level to use this command");
}
Re: Help! The gate not work -
Venice - 05.04.2011
not tested
pawn Code:
psur = CreateDynamicObject(971,-982.02215576,490.67080688,3.03113890,0.00000000,0.00000000,46.00000000); //puerta sur
CMD:ps(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 4 || IsPlayerAdmin(playerid)) {
MoveDynamicObject(psur, -982.02215576,490.67080688,-1.803113890, 3);
SendClientMessage(playerid, 0xFFFF00AA,"The Gate is opened.Welcome!");
return 1;
} else return SendClientMessage(playerid,COLOR_RED,"ERROR: You are not a high enough level to use this command");
}
or
pawn Code:
psur = CreateObject(971,-982.02215576,490.67080688,3.03113890,0.00000000,0.00000000,46.00000000); //puerta sur
CMD:ps(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 4 || IsPlayerAdmin(playerid)) {
MoveObject(psur, -982.02215576,490.67080688,-1.803113890, 3);
SendClientMessage(playerid, 0xFFFF00AA,"The Gate is opened.Welcome!");
return 1;
} else return SendClientMessage(playerid,COLOR_RED,"ERROR: You are not a high enough level to use this command");
}
Re: Help! The gate not work -
martini002 - 05.04.2011
LOL i got the problem, but ill not erase this post,
maybe someone have the same problem
if your are puting
psur = CreateDynamicObject(971,-982.02215............
is a DynamicObject so you need put it
MoveDynamicObject(psur, -982.0221.......................
and not
MoveObject(psur, -982.0221.................
im sorry im learning hehe
Re: Help! The gate not work -
Venice - 05.04.2011
im already post
Re: Help! The gate not work -
martini002 - 05.04.2011
Quote:
Originally Posted by venice
im already post
|
hehehe yes, at the same time,
thanks for answer venice
Re: Help! The gate not work -
martini002 - 05.04.2011
How to put a timer for close the door after 2 seconds?
Re: Help! The gate not work -
Venice - 05.04.2011
on up gamemode
pawn Code:
forward GateClose(playerid);
pawn Code:
public GateClose(playerid)
{
MoveDynamicObject(psur,-982.02215576,490.67080688,3.803113890, 3);
psur = 0;
return 1;
}
pawn Code:
psur = CreateObject(971,-982.02215576,490.67080688,3.03113890,0.00000000,0.00000000,46.00000000); //puerta sur
CMD:ps(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 4 || IsPlayerAdmin(playerid)) {
MoveObject(psur, -982.02215576,490.67080688,-1.803113890, 3);
SetTimer("GateClose", 10000, 0);
SendClientMessage(playerid, 0xFFFF00AA,"The Gate is opened.Gate Automatically Closed In 10 Seconds");
return 1;
} else return SendClientMessage(playerid,COLOR_RED,"ERROR: You are not a high enough level to use this command");
}
Re: Help! The gate not work -
martini002 - 05.04.2011
ok i have 3 doors with passwords,
so i need put all 3 doors in this code?
Code:
public GateClose(playerid)
{
MoveDynamicObject(psur,-982.02215576,490.67080688,3.803113890, 3);
psur = 0;
return 1;
}
Re: Help! The gate not work -
Venice - 06.04.2011
see this make urself.