Posts: 1,896
Threads: 102
Joined: Oct 2008
do i use this
pawn Код:
stock IsPlayerInArea(playerid, Float:max_x, Float:min_x, Float:max_y, Float:min_y)
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
if(X <= max_x && X >= min_x && Y <= max_y && Y >= min_y) return 1;
return 0;
}
i want to make it 99999999 health when you enter the zone and show some textdraw but where does SetPlayerHealth and TextDrawShowForPlayer go?
Posts: 1,896
Threads: 102
Joined: Oct 2008
pawn Код:
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1025) : error 004: function "IsPlayerInArea" is not implemented
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1028) : warning 213: tag mismatch
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1028) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1032) : warning 213: tag mismatch
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1032) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1036) : error 030: compound statement not closed at the end of file (started at line 1023)
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
2 Errors.
Posts: 2,896
Threads: 11
Joined: Sep 2008
Reputation:
0
Add the "IsPlayerInArea" function to your script.
Posts: 1,896
Threads: 102
Joined: Oct 2008
pawn Код:
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1021) : error 025: function heading differs from prototype
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : error 017: undefined symbol "max_X"
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1036) : warning 213: tag mismatch
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1036) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1040) : warning 213: tag mismatch
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1040) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1045) : error 030: compound statement not closed at the end of file (started at line 1031)
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
3 Errors.
Posts: 788
Threads: 22
Joined: May 2006
Reputation:
0
You are suppose to fill in the parts where he put like "....", "min_X" etc, put your values there.
Posts: 1,896
Threads: 102
Joined: Oct 2008
this is what ive got
pawn Код:
stock IsPlayerInArea(playerid, Float:max_x, Float:min_x, Float:max_y, Float:min_y)
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
if(1931.533813 <= max_x && 1323.255126 >= min_x && 2036.987426 <= max_y && 1364.370117 >= min_y) return 1;
return 0;
}
public InAreaChecker()
{
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerInArea(i, 1931.533813, 1323.255126, 2036.987426, 1364.370117))
{
SetPlayerHealth(i, 9999999);
TextDrawShowForPlayer(Textdraw30);
}
else
{
TextDrawHideForPlayer(Textdraw30);
SetPlayerHealth(i, 100);
}
}
and this is what comes out
pawn Код:
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1021) : error 025: function heading differs from prototype
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1036) : warning 213: tag mismatch
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1036) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1040) : warning 213: tag mismatch
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1040) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1045) : error 030: compound statement not closed at the end of file (started at line 1031)
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
2 Errors.
Posts: 1,896
Threads: 102
Joined: Oct 2008
with mademans code i get these now
pawn Код:
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1021) : error 025: function heading differs from prototype
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
C:\DOCUME~1\Jake\Desktop\SAMP-S~1\GAMEMO~1\DMA.pwn(1033) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
1 Error.
Posts: 3,488
Threads: 16
Joined: Jun 2007
Reputation:
0
Can you show lines 1021 and 1033?