SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 12/11/2011, 08:14 AM   #1
Stefand
Gangsta
 
Stefand's Avatar
 
Join Date: Sep 2011
Location: The Netherlands
Posts: 772
Reputation: 30
Default Why my Checkpoint wont work?

hi users,

Im trying to script a little but im not lucky xD

can someone help me with this

Code:
if(IsPlayerConnectedEx(GetPlayerID(text)))
			        {
						new location[MAX_ZONE_NAME];
						GetPlayer2DZone(playerid, location, MAX_ZONE_NAME);
			            format(string, sizeof(string), "911: %s has reported %s for %s (tracked from %s)", GetName(playerid), GetPlayerID(text), Player[playerid][ActiveCrimeReport], location);
						for(new i = 0; i < MAX_PLAYERS; i++)
						{
							if(IsPlayerConnectedEx(i))
						   	{
						   		if(Groups[Player[i][Group]][CommandTypes] == 1 && Player[i][CopDuty] == 1)
						   		{
						   		    SendClientMessage(i, RED, string);
						   		}
							}
						}
i want if the Police or FMD get this call they get a checkpoint on there map where the crime or accident is.
can someone help me with this?
__________________


Scripter & Mapper
_______________________
Stefand is offline   Reply With Quote
Old 12/11/2011, 10:32 AM   #2
CyNiC
High-roller
 
Join Date: Jan 2009
Location: Brazil
Posts: 1,420
Reputation: 203
Default Re: Why my Checkpoint wont work?

I don't see none SetPlayerCheckpoint there.

pawn Code:
if(IsPlayerConnectedEx(GetPlayerID(text)))
{
    new location[MAX_ZONE_NAME], pos[3];
    GetPlayer2DZone(playerid, location, MAX_ZONE_NAME);
    GetPlayerPos(playerid, pos[0], pos[1], pos[1]);
    format(string, sizeof(string), "911: %s has reported %s for %s (tracked from %s)", GetName(playerid), GetPlayerID(text), Player[playerid][ActiveCrimeReport], location);
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnectedEx(i))
        {
            if(Groups[Player[i][Group]][CommandTypes] == 1 && Player[i][CopDuty] == 1)
            {
                SendClientMessage(i, RED, string);
                SetPlayerCheckpoint(i, pos[0], pos[1], pos[2], 5.0);
            }
        }
    }
__________________
My scripts
Brazucas'Server
CyNiC is offline   Reply With Quote
Old 12/11/2011, 12:11 PM   #3
Stefand
Gangsta
 
Stefand's Avatar
 
Join Date: Sep 2011
Location: The Netherlands
Posts: 772
Reputation: 30
Default Re: Why my Checkpoint wont work?

it gives 4 errors at my pawno
__________________


Scripter & Mapper
_______________________
Stefand is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Checkpoint wont show up! csoki2 Help Archive 12 19/04/2011 12:55 PM
Why wont this work yarrum3 Client Support 2 31/01/2011 05:39 AM
Why wont this work yarrum3 Help Archive 2 28/12/2010 08:27 PM
Checkpoint wont appear? iTorran Help Archive 15 30/09/2010 04:45 PM
Checkpoint wont show up. Chrham_2 Help Archive 0 20/02/2010 04:49 PM


All times are GMT. The time now is 04:35 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.