Remove PLEASE! -
[LNL]Remulis - 03.05.2010
Got IT!
Re: OnPlayerKeyStateChange Problem! -
[LNL]Remulis - 03.05.2010
Somenone ? Srry for 2posting!
Re: OnPlayerKeyStateChange Problem! -
Assyria - 03.05.2010
Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_SECONDARY_ATTACK)
{
if(IsPlayerInRangeOfPoint(playerid, 7.0, -1106.2183,-299.7328,74.5391))
{
SetPlayerPos(playerid,2221.8914,1983.8129,26.2993);
}
}
}
And did you notice that your IsPlayerRangeOfPoint is in kinda weird place with very small range?
Re: OnPlayerKeyStateChange Problem! -
[LNL]Remulis - 03.05.2010
So what sould it be ?
Re: OnPlayerKeyStateChange Problem! -
Assyria - 03.05.2010
You have to be very near position: (-1106.2183,-299.7328,74.5391), so that the enter key warps you...
But maybe that is what you want..?
Re: OnPlayerKeyStateChange Problem! -
[LNL]Remulis - 03.05.2010
Oh thanks
Going to try
Re: OnPlayerKeyStateChange Problem! -
[LNL]Remulis - 03.05.2010
Wont work dont know why can u test it on ur script please ?
Quote:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_SECONDARY_ATTACK)
{
if(IsPlayerInRangeOfPoint(playerid, 50.0, -1106.2183,-299.7328,74.5391))
{
SetPlayerPos(playerid,2221.8914,1983.8129,26.2993) ;
}
}
}
|
Put ur own cordinates
Re: OnPlayerKeyStateChange Problem! -
Assyria - 03.05.2010
It works, you can see it by doing this:
Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_SECONDARY_ATTACK)
{
if(IsPlayerInRangeOfPoint(playerid, 10000, -1106.2183,-299.7328,74.5391))
{
SetPlayerPos(playerid,2221.8914,1983.8129,26.2993);
}
}
}
or removing the whole IsPlayerInRangeOfPoint
if(IsPlayerInRangeOfPoint(playerid, Range, X,Y,Z)) so it means that If you are in some position with range, then the thing works what you are trying to do.
For example: if(IsPlayerInRangeOfPoint(playerid, 50, 0,0,3)) Means that if you are in 50(meters) from position 0 0 3, your thing does its thing, else it wont.
Re: OnPlayerKeyStateChange Problem! -
[LNL]Remulis - 03.05.2010
Wow it works nime thanks. You can remove this topic!
Re: OnPlayerKeyStateChange Problem! -
Assyria - 03.05.2010
If you don't want to use it with some position, use this:
Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_SECONDARY_ATTACK)
{
SetPlayerPos(playerid,2221.8914,1983.8129,26.2993);
}
}