new fal = 12345;cmd:fal {new float:x new float:ynew float:zGetPlayerPos(x,y,z)createobject(fal,x,y,z,0.0,0.0,0.0);}cmd:rombol{if(/ide kellene hogy hogytudom lekérdezni azt hogy van-e a közeléb fal változós object){ RemoveObject(fal);//ide meg hogy csak azt törölje }}
Hogy kell azt megcsinálni hogy a kaput milyen messzirõl tudjam nyitni? [/quote] If(IsPlayerInRangeOfPoint(playerid,5.0, x, y, z);//az 5.0 a távolság az adott ponttól, tetszés szerint változtathatod...
If(IsPlayerInRangeOfPoint(playerid,5.0, x, y, z);//az 5.0 a távolság az adott ponttól, tetszés szerint változtathatod...
és ezt mi alá kell bemásolnom? [/quote]attól függ, mihez akarod...ha pl parancsra akarod nyitni a kaput, akkor a parancs alá eztt írod, és alá, a kapu nyitást...viszont ha magától akarod, hogy nyíljon, akkor timerre kell kötnöd.
hátt nekem hibát ad ki :S [/quote]máspld be a kódot, meg a hibaüzenetet
#include forward Csukodjbe();//SZINEK//----------------[]Szinkodók[]------------------------#define FEHER 0xFFFFFFAA#define COLOR_GREY 0xAFAFAFAA#define COLOR_GREEN 0x33AA33AA#define COLOUR_GREEN 0x33AA33AA#define COLOR_YELLOW 0xFFFF00AA#define COLOUR_YELLOW 0xFFFF00AA#define COLOR_PURPLE 0x9900FFAA#define COLOR_BROWN 0x993300AA#define COLOR_ORANGE 0xFF9933AA#define COLOR_CYAN 0x99FFFFAA#define COLOR_TAN 0xFFFFCCAA#define COLOR_PINK 0xFF66FFAA#define COLOR_KHAKI 0x999900AA#define COLOR_LIME 0x99FF00AA#define COLOR_ERROR 0xFF202020#define COLOR_GRAD2 0xBFC0C2FF#define COLOR_BLACK 0x000000AA#define COLOR_TURQ 0x00A3C0AA#define COLOR_LIGHTBLUE 0x00BFFFAA#define COLOR_GREENISHGOLD 0xCCFFDD56#define COLOR_LIGHTBLUEGREEN 0x0FFDD349#define COLOR_NEUTRALBLUE 0xABCDEF01#define COLOR_LIGHTCYAN 0xAAFFCC33#define COLOR_LEMON 0xDDDD2357#define COLOR_AQUA 0x7CFC00AA#define COLOR_WHITEYELLOW 0xFFE87DAA#define COLOR_BLUEAQUA 0x7E60FFAA#define COLOR_GREENYELLOWWHITE 0xCBFF45AA#define COLOR_DARKBLUE 0x15005EAA#define COLOR_RED 0xff0000AA#define piros 0xff0000AA#define COLOR_ROB_SUCCESS 0x00CCFFAA#define COLOR_ROB_FAILURE 0xCCCCFFAA#define COLOR_ROB_ERROR 0xFF0000AA#define COLOR_ALIEN 0x90FF87FF#define COLOR_SHOOTER 0xFFAC82FF#define COLOR_WHITE 0xFFFFD5FF#define COLOR_BLUE (0x0000FFAA)#define GELTONA 0xFFFF00FF#define BALTA 0xFFFFFFFF#define COLOUR_RED 0xEB000FFF#define COLOR_TRANSPARENT 0xFFFFFF00#define COLOR_GREY 0xAFAFAFAA#define COLOR_LBLUE 0x17ddebAA#define COL_EASY \"{FFF1AF}\"#define COL_WHITE \"{FFFFFF}\"#define COL_BLACK \"{0E0101}\"#define COL_GREY \"{C3C3C3}\"#define COL_GREEN \"{6EF83C}\"#define COL_RED \"{F81414}\"#define COL_CYAN \"{00FFEE}\"#define COL_LIGHTBLUE \"{00C0FF}\"#define COL_BLUE \"{0049FF}\"#define COL_MAGENTA \"{F300FF}\"#define COL_VIOLET \"{B700FF}\"#define COL_PINK \"{FF00EA}\"#define COL_MARONE \"{A90202}\"#define COL_CMD \"{B8FF02}\"#define COL_PARAM \"{3FCD02}\"#define COL_SERVER \"{AFE7FF}\"#define COL_VALUE \"{A3E4FF}\"#define COL_RULE2 \"{FBDF89}\"#define COL_RWHITE \"{FFFFFF}\"#define COL_LGREEN \"{C9FFAB}\"#define COL_LRED \"{FFA1A1}\"#define COL_LRED2 \"{C77D87}\"#define COLOR_YELLOW 0xFFFF00AA //SZINEK VÉGEnew kapu;new timer;public OnGameModeInit()CreateObject(16409, -2990.447753, 477.329681, 3.856916, 0.000000, 0.000000, 179.699996);//asdpublic OnFilterScriptInit(){kapu = CreateObject(11319, -2983.099853, 478.314666, 5.274063, 0.000000, 0.000000, 0.000000);//asdreturn 1;}public OnFilterScriptExit(){KillTimer(timer);return 1;} public OnPlayerCommandText(playerid, cmdtext[]){if (strcmp(\"/kgarazs2\", cmdtext, true, 10) == 0){ SendClientMessage(playerid, COLOR_WHITE, \"10másodperc múlva záródik!\");MoveObject(kapu, -2983.099853, 478.314666, 0.974063, 2.0);timer = SetTimerEx(\"Csukodjbe\",10000,0,\"i\",playerid); if(IsPlayerInRangeOfPoint(playerid,5.0,-2983.099853, 478.314666, 0.974063);//az 5.0 a távolság az adott ponttól, tetszés szerint változtathatod...return 1;}return 0;}public Csukodjbe(){MoveObject(kapu, -2983.099853, 478.314666, 5.274063, 2.0);}
if(IsPlayerInRangeOfPoint(playerid,5.0,-2983.099853, 478.314666, 0.974063))
KÓD: #include forward Csukodjbe();//SZINEK//----------------[]Szinkodók[]------------------------#define FEHER 0xFFFFFFAA#define COLOR_GREY 0xAFAFAFAA#define COLOR_GREEN 0x33AA33AA#define COLOUR_GREEN 0x33AA33AA#define COLOR_YELLOW 0xFFFF00AA#define COLOUR_YELLOW 0xFFFF00AA#define COLOR_PURPLE 0x9900FFAA#define COLOR_BROWN 0x993300AA#define COLOR_ORANGE 0xFF9933AA#define COLOR_CYAN 0x99FFFFAA#define COLOR_TAN 0xFFFFCCAA#define COLOR_PINK 0xFF66FFAA#define COLOR_KHAKI 0x999900AA#define COLOR_LIME 0x99FF00AA#define COLOR_ERROR 0xFF202020#define COLOR_GRAD2 0xBFC0C2FF#define COLOR_BLACK 0x000000AA#define COLOR_TURQ 0x00A3C0AA#define COLOR_LIGHTBLUE 0x00BFFFAA#define COLOR_GREENISHGOLD 0xCCFFDD56#define COLOR_LIGHTBLUEGREEN 0x0FFDD349#define COLOR_NEUTRALBLUE 0xABCDEF01#define COLOR_LIGHTCYAN 0xAAFFCC33#define COLOR_LEMON 0xDDDD2357#define COLOR_AQUA 0x7CFC00AA#define COLOR_WHITEYELLOW 0xFFE87DAA#define COLOR_BLUEAQUA 0x7E60FFAA#define COLOR_GREENYELLOWWHITE 0xCBFF45AA#define COLOR_DARKBLUE 0x15005EAA#define COLOR_RED 0xff0000AA#define piros 0xff0000AA#define COLOR_ROB_SUCCESS 0x00CCFFAA#define COLOR_ROB_FAILURE 0xCCCCFFAA#define COLOR_ROB_ERROR 0xFF0000AA#define COLOR_ALIEN 0x90FF87FF#define COLOR_SHOOTER 0xFFAC82FF#define COLOR_WHITE 0xFFFFD5FF#define COLOR_BLUE (0x0000FFAA)#define GELTONA 0xFFFF00FF#define BALTA 0xFFFFFFFF#define COLOUR_RED 0xEB000FFF#define COLOR_TRANSPARENT 0xFFFFFF00#define COLOR_GREY 0xAFAFAFAA#define COLOR_LBLUE 0x17ddebAA#define COL_EASY \"{FFF1AF}\"#define COL_WHITE \"{FFFFFF}\"#define COL_BLACK \"{0E0101}\"#define COL_GREY \"{C3C3C3}\"#define COL_GREEN \"{6EF83C}\"#define COL_RED \"{F81414}\"#define COL_CYAN \"{00FFEE}\"#define COL_LIGHTBLUE \"{00C0FF}\"#define COL_BLUE \"{0049FF}\"#define COL_MAGENTA \"{F300FF}\"#define COL_VIOLET \"{B700FF}\"#define COL_PINK \"{FF00EA}\"#define COL_MARONE \"{A90202}\"#define COL_CMD \"{B8FF02}\"#define COL_PARAM \"{3FCD02}\"#define COL_SERVER \"{AFE7FF}\"#define COL_VALUE \"{A3E4FF}\"#define COL_RULE2 \"{FBDF89}\"#define COL_RWHITE \"{FFFFFF}\"#define COL_LGREEN \"{C9FFAB}\"#define COL_LRED \"{FFA1A1}\"#define COL_LRED2 \"{C77D87}\"#define COLOR_YELLOW 0xFFFF00AA //SZINEK VÉGEnew kapu;new timer;public OnGameModeInit()CreateObject(16409, -2990.447753, 477.329681, 3.856916, 0.000000, 0.000000, 179.699996);//asdpublic OnFilterScriptInit(){kapu = CreateObject(11319, -2983.099853, 478.314666, 5.274063, 0.000000, 0.000000, 0.000000);//asdreturn 1;}public OnFilterScriptExit(){KillTimer(timer);return 1;} public OnPlayerCommandText(playerid, cmdtext[]){if (strcmp(\"/kgarazs2\", cmdtext, true, 10) == 0){ SendClientMessage(playerid, COLOR_WHITE, \"10másodperc múlva záródik!\");MoveObject(kapu, -2983.099853, 478.314666, 0.974063, 2.0);timer = SetTimerEx(\"Csukodjbe\",10000,0,\"i\",playerid); if(IsPlayerInRangeOfPoint(playerid,5.0,-2983.099853, 478.314666, 0.974063);//az 5.0 a távolság az adott ponttól, tetszés szerint változtathatod...return 1;}return 0;}public Csukodjbe(){MoveObject(kapu, -2983.099853, 478.314666, 5.274063, 2.0);} Hiba üzentet:C:\\Users\\Zsolti\\Desktop\\Impossible\\filterscripts\\PPGarazs.pwn(103) : error 001: expected token: \")\", but found \";\"C:\\Users\\Zsolti\\Desktop\\Impossible\\filterscripts\\PPGarazs.pwn(103) : error 036: empty statementPawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase2 Errors. [/quote]ennek mûködnie kell....... #include forward Csukodjbe();new kapu;new timer; public OnFilterScriptInit(){ CreateObject(16409, -2990.447753, 477.329681, 3.856916, 0.000000, 0.000000, 179.699996);//asdkapu = CreateObject(11319, -2983.099853, 478.314666, 5.274063, 0.000000, 0.000000, 0.000000);//asdreturn 1;}public OnFilterScriptExit(){KillTimer(timer);return 1;} public OnPlayerCommandText(playerid, cmdtext[]){if(strcmp(\"/kgarazs2\", cmdtext, true, 10) == 0){ if(IsPlayerInRangeOfPoint(playerid,5.0,-2983.099853, 478.314666, 0.974063)) { SendClientMessage(playerid, 0xffffffaa, \"10másodperc múlva záródik!\"); MoveObject(kapu, -2983.099853, 478.314666, 0.974063, 2.0); timer = SetTimerEx(\"Csukodjbe\",10000,0,\"i\",playerid); } return 1; } return 0;}public Csukodjbe(){MoveObject(kapu, -2983.099853, 478.314666, 5.274063, 2.0);}
#include forward Csukodjbe();new kapu;new timer; public OnFilterScriptInit(){ CreateObject(16409, -2990.447753, 477.329681, 3.856916, 0.000000, 0.000000, 179.699996);//asdkapu = CreateObject(11319, -2983.099853, 478.314666, 5.274063, 0.000000, 0.000000, 0.000000);//asdreturn 1;}public OnFilterScriptExit(){KillTimer(timer);return 1;} public OnPlayerCommandText(playerid, cmdtext[]){if(strcmp(\"/kgarazs2\", cmdtext, true, 10) == 0){ if(IsPlayerInRangeOfPoint(playerid,5.0,-2983.099853, 478.314666, 0.974063)) { SendClientMessage(playerid, 0xffffffaa, \"10másodperc múlva záródik!\"); MoveObject(kapu, -2983.099853, 478.314666, 0.974063, 2.0); timer = SetTimerEx(\"Csukodjbe\",10000,0,\"i\",playerid); } return 1; } return 0;}public Csukodjbe(){MoveObject(kapu, -2983.099853, 478.314666, 5.274063, 2.0);}
Üdv valaki tud segiteni hogy adminnak szines idje legyen? Ladmin4v2 használok. Admin:PiCsUUU [3]:assssNem admin.PiCsUUU [3]:asss
new string[256];if(IsPlayerLAdmin(playerid)){format(string, sizeof(string), \"%s (színkód}[%d]: {ffffff}%s\", GetPlayerName(playerid), playerid, text);}else{format(string, sizeof(string), \"%s (ffffff}[%d]:{ffffff} %s\", GetPlayerName(playerid), playerid, text);}return SendClientMessageToAll(GetPlayerColor(playerid), string);
#include <IsPlayerLAdmin>
C:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(9) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(9) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(13) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(13) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(16) : warning 225: unreachable code
Ezeket irta ki..C:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(9) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(9) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(13) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(13) : warning 202: number of arguments does not match definitionC:\\Users\\Levente\\Desktop\\Bandaháborúk szerver\\filterscripts\\id.pwn(16) : warning 225: unreachable code
public OnPlayerText(playerid, text[]){new string[256];if(IsPlayerLAdmin(playerid)){format(string, sizeof(string), \"%s (színkód}[%d]: {ffffff}%s\", GetPlayerName(playerid), playerid, text);}else{format(string, sizeof(string), \"%s (ffffff}[%d]:{ffffff} %s\", GetPlayerName(playerid), playerid, text);}return SendClientMessageToAll(GetPlayerColor(playerid), string);}