More moveable gates problem -
NickTaSpy - 02.03.2012
Hello there.I have a problem with my friends.We are recently putting moveable gates with commands like /opengate1 or /closegate1.The problem is that if we put their script in the gamemode, they are bugged(looks like the position of the gate when you type the command is different/broken).So we put them in a filterscript but if we put more than 3 moveable gates, then we meet bugs on them again.What can we do to create more than 3 moveable gates in our server without bugs?
Any ideas?
Re: More moveable gates problem -
Mike_Peterson - 02.03.2012
Any codes? Any pics? Any
MORE information about 'bugs'?
Re: More moveable gates problem -
NickTaSpy - 02.03.2012
pawn Код:
new antonispark
if (strcmp("/xXx", cmdtext, true, 10) == 0)
{
MoveObject(antonispark, 2615.85791016,2302.76464844,12.59370422, 5.00);
return 1;
}
This is a part of the script.I put the "new" on the top(the name of the gate) then I make the command to open the gate and another one to close it.At the moment we have three gates fully working.If we put another one, it will be bugged.
Example:
I put a new gate(which is bugged).I am going to the gate to check if it works.I am looking to it.Now I press the command to open the gate.But the gate doesn't go to the right position which I have told it to go.Although if I close it again, it will go to the right place.
Re: More moveable gates problem -
Mike_Peterson - 02.03.2012
And, you're making new variables for every new gate I hope? and have you checked the coords at all? They might be the wrong ones?
Re: More moveable gates problem -
NickTaSpy - 02.03.2012
Quote:
Originally Posted by Mike_Peterson
And, you're making new variables for every new gate I hope? and have you checked the coords at all? They might be the wrong ones?
|
Yes, I create different lines for each new gate.And my friend has checked the coords, they are right.
Re: More moveable gates problem -
Mike_Peterson - 02.03.2012
Okay, because it's a problem with moveable gates, a picture would help alot.
Oh and is the gate rotating? according to your code it doesn't, just to let you know.
Re: More moveable gates problem -
NickTaSpy - 02.03.2012
Quote:
Originally Posted by Mike_Peterson
Okay, because it's a problem with moveable gates, a picture would help alot.
Oh and is the gate rotating? according to your code it doesn't, just to let you know.
|
We don't make the gates rotating.The rotation number is the same in both commands and the map object.
I will post screenshots as soon as my friends create a gate so I take proof of the bug.
Re: More moveable gates problem -
Walsh - 02.03.2012
You are never assigning the variable to an object.
Example
pawn Код:
new gate;
public OnGameModeInit()
{
gate = CreateObject(params here);
return 1;
}
Re: More moveable gates problem -
NickTaSpy - 03.03.2012
Quote:
Originally Posted by Walsh
You are never assigning the variable to an object.
Example
pawn Код:
new gate;
public OnGameModeInit() { gate = CreateObject(params here); return 1; }
|
That goes where?Under the "new" on top of script?Please more details, I am not pro at scripting.
Re: More moveable gates problem -
Walsh - 03.03.2012
Quote:
Originally Posted by NickTaSpy
That goes where?Under the "new" on top of script?Please more details, I am not pro at scripting.
|
The "new" goes on top of the script.