02.08.2012, 16:16
Hi Guys
Im creating A trucking Server Im Not Able to Get the /work command for missions
Im creating A trucking Server Im Not Able to Get the /work command for missions
//
#include <a_samp>
#include <float>
//Colors
#define COLOR_RED 0xFF0000AA
#define COLOR_GREEN 0x00FF00AA
#define COLOR_BLUE 0x0000FFAA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_ORANGE 0xFFA500AA
#define COLOR_MENU 0xADFF2FAA //Green/Yellow
#define COLOR_MENUHEADER 0x7CFC00AA
#define COLOR_AQUA 0x66CDAAAA
forward PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z);
//news
#pragma tabsize 0
public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" work cmd");
print("--------------------------------------\n");
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (!strcmp("/work", cmdtext, true))
{
SendClientMessage(playerid, 0xFFFF00AA,"You are delivering wastee from .. to ........");
SetPlayerCheckpoint(playerid, X, Y, Z, 10.0);
}
}
return 1;
}
return 0;
}
public OnPlayerEnterCheckpoint(playerid)
{
if(IsPlayerInRangeOfPoint(playerid, 5.0, X, Y, Z)){
GivePlayerMoney(playerid, 23123);
DisablePlayerCheckpoint(playerid);
SendClientMessage(playerid, COLOR_YELLOW, "You Delivered Waste From .... To ..");
new str[128],name[MAX_PLAYER_NAME]; GetPlayerName(playerid, name, 24); format(str, sizeof(str), "%s Has Delivered Waste From .......... To ......... ", name); SendClientMessageToAll(0xFFFF00AA, str);
return 1;
}
Change x,y,z !
... Name of Place pawn Код:
|
Im getting errors
C:\Documents and Settings\JSM\Desktop\Own server\gamemodes\trucking.pwn(122) : error 010: invalid function or declaration C:\Documents and Settings\JSM\Desktop\Own server\gamemodes\trucking.pwn(124) : error 010: invalid function or declaration Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 2 Errors. |
public OnPlayerCommandText(playerid, cmdtext[])
{
if (!strcmp("/work", cmdtext, true))
{
SendClientMessage(playerid, 0xFFFF00AA,"You are delivering wastee from .. to ........");
SetPlayerCheckpoint(playerid, X, Y, Z, 10.0);
return 1;
}
return 1;
}