|
#include <a_samp> #include <core> #include <float> #define verde 0x33AA33AA new Puerta6; new Puerta7; new Puerta8; public OnFilterScriptInit() { Puerta6 = CreateObject(1493, 250.75250244141, 61.779201507568, 1002.640625, 0, 0, 89.324493408203); Puerta7 = CreateObject(1493, 250.71475219727, 64.817604064941, 1002.640625, 0.00000000000, 0.00000000000, 270.67370605469); Puerta8 = CreateObject(974, 250.76702880859, 68.138221740723, 1006.1683349609, 0.00000000000, 89.325012207031, 270.67565917969); return 1; } public OnPlayerCommandText(playerid, cmdtext[]) { if (strcmp("/ap1", cmdtext, true) == 0) //para abrir la puerta { if(IsPlayerInRangeOfPoint(playerid, 15.0, 250.75250244141, 61.779201507568, 1002.640625)){ //si el jugador no esta en un radio de 15.0 a la puerta no lo dejara usar el comando. (Reemplazar las coordenadas por las coordenadas de nuestra puerta (CERRADA)) MoveObject(Puerta6, 250.7060546875, 60.446472167969, 1002.640625, 3.0); //mueve nuestra puerta hasta las coordenadas de la puerta abierta. (Reemplazar las coordenadas por las coordenadas de nuestra puerta (ABIERTA)) MoveObject(Puerta7, 250.73263549805, 65.595016479492, 1002.640625, 3.0); return SendClientMessage(playerid, 0x28F943FF, "Server: Has abierto la puerta"); }else return SendClientMessage(playerid, 0xFF0000FF, "ERROR: Debes estar cerca de la puerta para usar este comando"); } if (strcmp("/cp1", cmdtext, true) == 0) //cerrar { if(IsPlayerInRangeOfPoint(playerid, 15.0, 250.75250244141, 61.779201507568, 1002.640625)){ //si el jugador no esta en un radio de 15.0 a la puerta no lo dejara usar el comando. (Reemplazar las coordenadas por las coordenadas de nuestra puerta (CERRADA)) MoveObject(Puerta6, 250.75250244141, 61.779201507568, 1002.640625, 3.0); //mueve nuestra puerta hasta las coordenadas de la puerta abierta. (Reemplazar las coordenadas por las coordenadas de nuestra puerta (CERRADA)) MoveObject(Puerta7, 250.71475219727, 64.817604064941, 1002.640625, 3.0); return SendClientMessage(playerid, 0x28F943FF, "Server: Has cerrado la puerta"); }else return SendClientMessage(playerid, 0xFF0000FF, "ERROR: Debes estar cerca de la puerta para usar este comando"); } |
if(PlayerInfo[playerid][pMember] == (Numero Faccion) || PlayerInfo[playerid][pLeader] == (Numero Faccion))
if(PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pLeader] == 10)
|
Originally Posted by FelipekxD
En el public OnPlayerCommandText, en cada comando necesitas colocarle, arriba de: IsPlayerInRangeOfPoint, agrega esto:
pawn Код:
pawn Код:
|
|
C:\Documents and Settings\Propietario\Escritorio\RolePlay - By GroX0r - SA-MP\filterscripts\PUERTASLSPD.pwn(27) : error 017: undefined symbol "PlayerInfo" C:\Documents and Settings\Propietario\Escritorio\RolePlay - By GroX0r - SA-MP\filterscripts\PUERTASLSPD.pwn(27) : warning 215: expression has no effect C:\Documents and Settings\Propietario\Escritorio\RolePlay - By GroX0r - SA-MP\filterscripts\PUERTASLSPD.pwn(27) : error 001: expected token: ";", but found "]" C:\Documents and Settings\Propietario\Escritorio\RolePlay - By GroX0r - SA-MP\filterscripts\PUERTASLSPD.pwn(27) : error 029: invalid expression, assumed zero C:\Documents and Settings\Propietario\Escritorio\RolePlay - By GroX0r - SA-MP\filterscripts\PUERTASLSPD.pwn(27) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors. |
|
Originally Posted by sergio3
Quote:
Quote:
|
)