Wysłany: 2012-05-02, 18:56
B!4CK
Never give UP!
Wiek: 32 Na forum: 5809 dni Posty: 1047
Nick w MP: John
Piwa : 1891
up@
Ca?y kod :
Kod: public OnVehicleDamageStatusUpdate(vehicleid, playerid)
{
GetVehicleDamageStatus(vehicleid,SamochodInfo[vehicleid][sUszkodzenia],SamochodInfo[vehicleid][sUszkodzenia2],SamochodInfo[vehicleid][sUszkodzenia3],SamochodInfo[vehicleid][sUszkodzenia4]);
new Float:hp;
if(GetVehicleHealth(vehicleid, hp)<OstatniStatus[vehicleid])
{
dDodajHP(playerid,-5);
OstatniStatus[vehicleid]=hp;
TextDrawShowForPlayer(playerid, Ekran);
Update3DTextLabelText(NICK[playerid], KOLOR_CZERWONY, NickWys(playerid)); //Errory
SetTimerEx("Nicki", 2000, 0, "u", playerid);
return 1;
}
return 1;
}
Podpis
Cześć
[you]
!
Projekt, który poruszy scenę platformy SA:MP!
Wysłany: 2012-05-04, 09:46
Logitech12
Wiek: 31 Na forum: 5346 dni Posty: 5
Nick w MP: [_Logitech_]
C:\Users\Home\Desktop\Gry\SAMP\pawno\include\strtok.inc(12) : error 021: symbol already defined: "strtok"
C:\Users\Home\Desktop\Gry\SAMP\pawno\include\strtok.inc(27) : error 047: array sizes do not match, or destination array is too small
C:\Users\Home\Desktop\PolskiFreeroamek2.0.pwn(21263) : error 017: undefined symbol "strrest"
C:\Users\Home\Desktop\PolskiFreeroamek2.0.pwn(21263) : error 033: array must be indexed (variable "BReason")
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
pomocy !
Wysłany: 2012-05-04, 18:49
Cracku
Wiek: 35 Na forum: 5407 dni Posty: 26
Siemka mam problem z warningiem 225
Kod: C:\Users\Crack\Desktop\Nowy folder\Mapka By Adiman\Mapka By Adiman\Adiman2011.pwn(7230) : warning 225: unreachable code
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
Header size: 4704 bytes
Code size: 255432 bytes
Data size: 307892 bytes
Stack/heap size: 16384 bytes; estimated max. usage=4236 cells (16944 bytes)
Total requirements: 584412 bytes
1 Warning.
Oto kod od 7230 do 7261
Kod: if((newkeys==KEY_FIRE)&&(IsPlayerInAnyVehicle(playerid))&&(GetPlayerState(playerid)==PLAYER_STATE_DRIVER))
{
if (GetVehicleModel(GetPlayerVehicleID(playerid)) == 525)
{
new Float:pX,Float:pY,Float:pZ;
GetPlayerPos(playerid,pX,pY,pZ);
new Float:vX,Float:vY,Float:vZ;
new Found=0;
new vid=0;
while((vid<MAX_VEHICLES)&&(!Found))
{
vid++;
GetVehiclePos(vid,vX,vY,vZ);
if ((floatabs(pX-vX)<7.0)&&(floatabs(pY-vY)<7.0)&&(floatabs(pZ-vZ)<7.0)&&(vid!=GetPlayerVehicleID(playerid)))
{
Found=1;
if (IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid)))
{
DetachTrailerFromVehicle(GetPlayerVehicleID(playerid));
}
AttachTrailerToVehicle(vid,GetPlayerVehicleID(playerid));
}
}
}
if(newkeys==KEY_SPRINT && GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
{
ApplyAnimation(playerid,"PED","run_fatold",4.1,0,1,1,1,5);
}
}
return 1;
}
Wysłany: 2012-05-04, 18:51
B!4CK
Never give UP!
Wiek: 32 Na forum: 5809 dni Posty: 1047
Nick w MP: John
Piwa : 1891
up@ Warning przeszkadza? Tzn s? przez niego jakie? bugi
Spokojnie je?li nic nie przeszkadza mo?esz gra? na warningach.
Podpis
Cześć
[you]
!
Projekt, który poruszy scenę platformy SA:MP!
Wysłany: 2012-05-05, 14:31
sirelton
Mlodszy paffner :D
Wiek: 39 Na forum: 5185 dni Posty: 42
Nick w MP: Adagio
Piwa : 180
WItam mam taki problem z map? wyskakuj? takie errory:
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(22) : error 017: undefined symbol "MAX_PLAYERS"
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(22) : error 009: invalid array size (negative, zero or out of bounds)
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(189) : error 017: undefined symbol "GivePlayerMoney"
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(189) : warning 215: expression has no effect
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(189) : error 017: undefined symbol "GetPlayerMoney"
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(189) : warning 215: expression has no effect
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(189) : error 001: expected token: ";", but found ")"
C:\Documents and Settings\MATEUZEK\Pulpit\server sparingowy\tajemniczy\pawno\include\dutils.inc(189) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
6 Errors.
Tutaj macie link do mapy to mo?ecie zobaczy? czemu niedzia??.Prosze pomoc.
Wysłany: 2012-05-05, 22:03
Elegancik
Wiek: 36 Na forum: 5308 dni Posty: 8
Nick w MP: Tofik
Poka? kod z linijek z errorami -,-
Wysłany: 2012-05-06, 09:51
zajacp1
asdfghjnklngnbfs
Wiek: 28 Na forum: 6102 dni Posty: 610
Piwa : 726
sirelton , zaktualizuj include.
Wysłany: 2012-05-06, 16:01
ePiTeK
Wiek: 32 Na forum: 6521 dni Posty: 5
Nick w MP: epitek
Piwa : 1049
Kod: [14] Loading filterscript 'wyspasf.amx'...
[14] *** Streamer Plugin: Obsolete or invalid native found (script needs to be recompiled with the latest include file)
[14]
--------------------------------------
[14] Obiekty Innovation Truck Wyspa Za?adowana
[14] --------------------------------------
[14] Loading filterscript 'obiekts.amx'...
[14] *** Streamer Plugin: Obsolete or invalid native found (script needs to be recompiled with the latest include file)
[14]
--------------------------------------
[14] Obiekty Innovation Tiry Za?adowane :E
[14] --------------------------------------
[14] Loading filterscript 'obiekt.amx'...
[14] *** Streamer Plugin: Obsolete or invalid native found (script needs to be recompiled with the latest include file)
[14]
--------------------------------------
[14] Obiekty 2 za?adowane
[14] --------------------------------------
[14] Loading filterscript 'firmy.amx'...
[14] *** Streamer Plugin: Obsolete or invalid native found (script needs to be recompiled with the latest include file)
[14] Loading filterscript 'barierki.amx'...
[14] *** Streamer Plugin: Obsolete or invalid native found (script needs to be recompiled with the latest include file)
[14] Loaded 7 filterscripts.
Serwer przez to dostaje crashe, wie kto? jak zniwelowa? te errory?
Wysłany: 2012-05-06, 16:06
SzoteK
DriftPajace <3
Wiek: 32 Na forum: 5944 dni Posty: 143
Nick w MP: SzoteK
Piwa : 747
"ePiTeK" napisał/a :script needs to be recompiled with the latest include file
Tak trudno wrzuci? w google t?umacz?
Przekompiluj z najnowszymi include do pluginu..
Podpis
Tu był kot ale zjadł go Snoop Dogg
Wysłany: 2012-05-06, 18:04
staleczka12
Wiek: 29 Na forum: 6296 dni Posty: 29
Piwa : 287
Errory:
Kod:
I:\Documents and Settings\Grzesiu\Pulpit\serwer\pawno\include\dutils.inc(441) : warning 219: local variable "f" shadows a variable at a preceding level
I:\Documents and Settings\Grzesiu\Pulpit\gamemod.pwn(114) : error 017: undefined symbol "SetPlayerClass"
I:\Documents and Settings\Grzesiu\Pulpit\gamemod.pwn(116) : error 029: invalid expression, assumed zero
I:\Documents and Settings\Grzesiu\Pulpit\gamemod.pwn(116) : warning 215: expression has no effect
I:\Documents and Settings\Grzesiu\Pulpit\gamemod.pwn(116) : error 001: expected token: ";", but found "if"
I:\Documents and Settings\Grzesiu\Pulpit\gamemod.pwn(116) : error 017: undefined symbol "classid"
I:\Documents and Settings\Grzesiu\Pulpit\gamemod.pwn(116) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
5 Errors.
kod
Pawn #include <a_samp>
#include <dini>
#pragma tabsize 0
//========================= F R A K C J E ======================================
new gTeam [ MAX_PLAYERS ]; // Tworzenie Frakcji
new wlekarz [ MAX_PLAYERS ]; //W jakiej frakcji znajduje sie gracz
#define TEAM_LEKARZ 1
#define LEKARZ "lekarz.ini"
//========================== K O N I E C =======================================
//=================== S K R Z Y N I A B I E G ? W =============================
#define Loop(%0,%1) \
for(new % 0 ; % 0 != % 1 ; % 0 ++) // a very useful macro
#define GEAR_KEY KEY_FIRE // You can change this to what you want. I like key_fire.
new
timer [ MAX_PLAYERS ], // check timer
Text : GearInfo [ MAX_PLAYERS ], // R N D
Text : Speedo [ MAX_PLAYERS ], // speedometer
Text : General [ 5 ], // structure
Text : Gear [ 6 ], // bars
cGear [ MAX_VEHICLES ], // current gear
warn [ MAX_VEHICLES ], // vehicle speed to high/low
gul [ MAX_VEHICLES ] // which bar
;
forward ShiftFunction ( playerid );
//========================== K O N I E C =======================================*/
//========================= K O L O R K I ======================================
#define KOLOR_WEJSCIE_NA_SERWER 0x00AAFFFF
#define TURKUSOWY 0x00FFFFFF
#define COLOR_GMSC 0x004800FF
#define BEZOWY 0xFFFFADAA
#define BIALY 0xFFFFFFAA
#define BORDOWY 0x99001FAA
#define BRAZOWY 0x997A00AA
#define CIEMNY_ZIELONY 0x336633AA
#define CZARNY 0x000000AA
#define CZERWONY 0xFF0000AA
#define FIOLETOWY 0x9E3DFFAA
#define NIEBIESKI 0x0000FFAA
#define POMARANCZOWY 0xFF8000AA
#define ROZOWY 0xFF66CCAA
#define SZARY 0xB0B0B0AA
#define ZIELONY 0x00CC00AA
#define CIEMNY_NIEBIESKI 0x3F02A4FF
#define ZOLTY 0xFFFF00AA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_FIOLET 0x8000FFFF
#define COLOR_LIGHTBLUE 0x6DC5F3FF
#define COLOR_LIGHTYELLOW 0xFAEAA9FF
#define COLOR_LIGHTGREEN 0x00FF00FF
#define COLOR_LIGHTORANGE 0xF7A26FFF
#define COLOR_LIGHTRED 0xFF0000FF
#define COLOR_RED 0xAA3333AA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_RED 0xAA3333AA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_YELLOW2 0xFFFF00FF
#define COLOR_ORANGE 0xFF9900AA
#define COLOR_BLUE 0xFF9900AA
#define COLOR_SYSTEM 0xEFEFF7AA
#define COLOR_PINK 0xFF66FFAA
#define SPAWN_DELAY 3000
#define COLOR_KOMENDA 0xC83322FF
#define COLOR_GRAD1 0xC83322FF
#define COLOR_WIADOMOSC 0x00FF00FF
#define COLOR_BLACK 0x000000FF
#define COLOR_ADMIN 0xFF0000AA
//========================== K O N I E C =======================================
/*public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" Blank Filterscript by your name here");
print("--------------------------------------\n");
return 1;
}
public OnFilterScriptExit()
{
return 1;
}*/
public OnGameModeInit ()
{
if( dini_Exists ( LEKARZ )){
}
else
{
dini_Create ( LEKARZ );
}
// Don't use these lines if it's a filterscript
SetGameModeText ( "Blank Script" );
AddPlayerClass ( 0 , 1958.3783 , 1343.1572 , 15.3746 , 269.1425 , 0 , 0 , 0 , 0 , 0 , 0 );
AddPlayerClass ( 275 , 1958.3783 , 1343.1572 , 15.3746 , 269.1425 , 0 , 0 , 0 , 0 , 0 , 0 );
SetPlayerClass ( playerid , classid ) {
else if( classid == 0 ) { // zaczynamy od 0
DajDoLekarz ( playerid );
gTeam [ playerid ] = TEAM_LEKARZ ;
}
return 1 ;
}
public OnGameModeExit ()
{
return 1 ;
}
public OnPlayerRequestClass ( playerid , classid )
{
SetPlayerInterior ( playerid , 0 );
SetPlayerPos ( playerid , 258.4893 ,- 41.4008 , 1002.0234 );
SetPlayerFacingAngle ( playerid , 270.0 );
SetPlayerCameraPos ( playerid , 256.0815 ,- 43.0475 , 1004.0234 );
SetPlayerCameraLookAt ( playerid , 258.4893 ,- 41.4008 , 1002.0234 );
case 1 :
{
GameTextForPlayer ( playerid , "~y~L~w~ekarze" , 2000 , 6 );
}
return 1 ;
}
public OnPlayerConnect ( playerid )
{
ShowPlayerNameTagForPlayer ( playerid , 2 , 0 ); //ukrycie nicku gracza playerid dla gracza o id 2.
/*SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"------------------------------------------------------------------------------------------");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Witaj, %s na serwerze Drift King!");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Zach?camy do rejestracji na serwerze, unikniesz podszywania si?.");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Zapraszam do korzystania z unikalnych event?w drifterskich!");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Mo?esz sprawidzi? statystyki serwera na stronie: {FF0000}http://staty.d-k.net");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Prosz? o przeczytanie listy komend itp: {DD0000}/cmd");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"------------------------------------------------------------------------------------------");*/
//Skrzynia
GearInfo [ playerid ] = TextDrawCreate ( 596.000000 , 425.000000 , "~w~R ~g~~h~N ~w~D" );
TextDrawBackgroundColor ( GearInfo [ playerid ], 255 );
TextDrawFont ( GearInfo [ playerid ], 1 );
TextDrawLetterSize ( GearInfo [ playerid ], 0.320000 , 1.299999 );
TextDrawColor ( GearInfo [ playerid ], - 1 );
TextDrawSetOutline ( GearInfo [ playerid ], 0 );
TextDrawSetProportional ( GearInfo [ playerid ], 1 );
TextDrawSetShadow ( GearInfo [ playerid ], 1 );
Speedo [ playerid ] = TextDrawCreate ( 579.000000 , 414.000000 , "255 ~w~km/h" );
TextDrawBackgroundColor ( Speedo [ playerid ], 0x000000FF );
TextDrawFont ( Speedo [ playerid ], 1 );
TextDrawLetterSize ( Speedo [ playerid ], 0.170000 , 0.799999 );
TextDrawColor ( Speedo [ playerid ], 0xA803D0FF );
TextDrawSetOutline ( Speedo [ playerid ], 0 );
TextDrawSetProportional ( Speedo [ playerid ], 1 );
TextDrawSetShadow ( Speedo [ playerid ], 1 );
timer [ playerid ] = SetTimerEx ( "ShiftFunction" , 150 , true , "i" , playerid );
//Koniec
return 1 ;
}
stock GetSpeed ( playerid )
{
new Float : ST [ 3 ];
GetVehicleVelocity ( GetPlayerVehicleID ( playerid ), ST [ 0 ], ST [ 1 ], ST [ 2 ]);
return floatround ( 1.61 * floatsqroot ( floatpower ( floatabs ( ST [ 0 ]), 2.0 ) + floatpower ( floatabs ( ST [ 1 ]), 2.0 ) + floatpower ( floatabs ( ST [ 2 ]), 2.0 )) * 100.3 );
}
public OnPlayerDisconnect ( playerid , reason )
{
KillTimer ( timer [ playerid ]);
TextDrawDestroy ( GearInfo [ playerid ]);
TextDrawDestroy ( Speedo [ playerid ]);
return 1 ;
}
public OnPlayerSpawn ( playerid )
{
else if ( gTeam [ playerid ] == TEAM_LEKARZ ){
new nen [ 256 ];
format ( nen , 256 , "[Lekarz]%s" , Player ( playerid )); //Literka przy nicku gracza [P]
SetPlayerName ( playerid , nen );
SetPlayerColor ( playerid , 0xFFFFFF00 ); //Ustawiamy kolor frakcji, policja ma niewidoczny
SendClientMessage ( playerid , COLOR_LIGHTRED , "Witaj! Aby zobaczyж komendy pracownika wpisz /cmds" ); //Komendy pracownika zmieniamy na swoje
//Cbstat[playerid]=9; //Kanal CB jesli jest na serwerze
}
return 1 ;
}
public OnPlayerDeath ( playerid , killerid , reason )
{
if ( gTeam [ playerid ] == TEAM_LEKARZ ){
new PlayerNamex [ 256 ];
PlayerNamex = PlayerName ( playerid );
if( strfind ( PlayerNamex , "[Lekarz]" , false )!=- 1 ){
PlayerNamex = strreplace ( "[Lekarz]" , "" , PlayerName ( playerid ));
SetPlayerName ( playerid , PlayerNamex );
}
}
return 1 ;
}
public OnVehicleSpawn ( vehicleid )
{
return 1 ;
}
public OnVehicleDeath ( vehicleid , killerid )
{
return 1 ;
}
public OnPlayerText ( playerid , text [])
{
new str [ 128 ];
if( IsPlayerAdmin ( playerid ))
{
format ( str , sizeof str , "{99FF00}{99FF00}[ {00AAFF}%d # {FF0000}Admin {99FF00}]{FFFFFF}: %s" , playerid , text );
}
else
{
format ( str , sizeof str , "{99FF00}{99FF00}[ {00AAFF}%d # Gracz {99FF00}]{FFFFFF}: %s" , playerid , text );
}
SendPlayerMessageToAll ( playerid , str );
return false ;
}
public OnPlayerCommandText ( playerid , cmdtext [])
{
return 0 ;
}
public OnPlayerEnterVehicle ( playerid , vehicleid , ispassenger )
{
return 1 ;
}
public OnPlayerExitVehicle ( playerid , vehicleid )
{
return 1 ;
}
public OnPlayerStateChange ( playerid , newstate , oldstate )
{
if( newstate == PLAYER_STATE_DRIVER ) cGear [ GetPlayerVehicleID ( playerid )]= 1 ;
return 1 ;
}
public OnPlayerEnterCheckpoint ( playerid )
{
return 1 ;
}
public OnPlayerLeaveCheckpoint ( playerid )
{
return 1 ;
}
public OnPlayerEnterRaceCheckpoint ( playerid )
{
return 1 ;
}
public OnPlayerLeaveRaceCheckpoint ( playerid )
{
return 1 ;
}
public OnRconCommand ( cmd [])
{
return 1 ;
}
public OnPlayerRequestSpawn ( playerid )
{
f ( gTeam [ playerid ] == TEAM_LEKARZ && wlekarz [ playerid ] == 1 ){
return 1 ;
}
else if( gTeam [ playerid ] == TEAM_LEKARZ && wlekarz [ playerid ] != 1 ){
return 0 ;
}
return 1 ;
}
public OnObjectMoved ( objectid )
{
return 1 ;
}
public OnPlayerObjectMoved ( playerid , objectid )
{
return 1 ;
}
public OnPlayerPickUpPickup ( playerid , pickupid )
{
return 1 ;
}
public OnVehicleMod ( playerid , vehicleid , componentid )
{
return 1 ;
}
public OnVehiclePaintjob ( playerid , vehicleid , paintjobid )
{
return 1 ;
}
public OnVehicleRespray ( playerid , vehicleid , color1 , color2 )
{
return 1 ;
}
public OnPlayerSelectedMenuRow ( playerid , row )
{
return 1 ;
}
public OnPlayerExitedMenu ( playerid )
{
return 1 ;
}
public OnPlayerInteriorChange ( playerid , newinteriorid , oldinteriorid )
{
return 1 ;
}
public OnRconLoginAttempt ( ip [], password [], success )
{
return 1 ;
}
public OnPlayerUpdate ( playerid )
{
return 1 ;
}
public OnPlayerStreamIn ( playerid , forplayerid )
{
return 1 ;
}
public OnPlayerStreamOut ( playerid , forplayerid )
{
return 1 ;
}
public OnVehicleStreamIn ( vehicleid , forplayerid )
{
return 1 ;
}
public OnVehicleStreamOut ( vehicleid , forplayerid )
{
return 1 ;
}
public OnDialogResponse ( playerid , dialogid , response , listitem , inputtext [])
{
return 1 ;
}
public OnPlayerClickPlayer ( playerid , clickedplayerid , source )
{
return 1 ;
}
forward DajDoLekarz ( playerid );
public DajDoLekarz ( playerid )
{
if( strval ( dini_Get ( LEKARZ , Player ( playerid ))) == 1 )
wlekarz [ playerid ] = 1 ;
return 1 ;
}
Wysłany: 2012-05-06, 19:42
Sillence
Wiek: 26 Na forum: 5157 dni Posty: 1514
Nick w MP: Sillence
Piwa : 1517
staleczka12 , ?ap :
Kod: #include <a_samp>
#include <dini>
#include <dudb>
#pragma tabsize 0
//========================= F R A K C J E ======================================
new gTeam[MAX_PLAYERS];// Tworzenie Frakcji
new wlekarz[MAX_PLAYERS]; //W jakiej frakcji znajduje sie gracz
#define TEAM_LEKARZ 1
#define LEKARZ "lekarz.ini"
//========================== K O N I E C =======================================
//=================== S K R Z Y N I A B I E G ? W =============================
#define Loop(%0,%1) \
for(new %0; %0 != %1; %0++) // a very useful macro
#define GEAR_KEY KEY_FIRE // You can change this to what you want. I like key_fire.
new
timer[MAX_PLAYERS], // check timer
Text: GearInfo[MAX_PLAYERS], // R N D
Text: Speedo[MAX_PLAYERS], // speedometer
cGear[MAX_VEHICLES] // current gear
;
forward ShiftFunction(playerid);
//========================== K O N I E C =======================================*/
//========================= K O L O R K I ======================================
#define KOLOR_WEJSCIE_NA_SERWER 0x00AAFFFF
#define TURKUSOWY 0x00FFFFFF
#define COLOR_GMSC 0x004800FF
#define BEZOWY 0xFFFFADAA
#define BIALY 0xFFFFFFAA
#define BORDOWY 0x99001FAA
#define BRAZOWY 0x997A00AA
#define CIEMNY_ZIELONY 0x336633AA
#define CZARNY 0x000000AA
#define CZERWONY 0xFF0000AA
#define FIOLETOWY 0x9E3DFFAA
#define NIEBIESKI 0x0000FFAA
#define POMARANCZOWY 0xFF8000AA
#define ROZOWY 0xFF66CCAA
#define SZARY 0xB0B0B0AA
#define ZIELONY 0x00CC00AA
#define CIEMNY_NIEBIESKI 0x3F02A4FF
#define ZOLTY 0xFFFF00AA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_FIOLET 0x8000FFFF
#define COLOR_LIGHTBLUE 0x6DC5F3FF
#define COLOR_LIGHTYELLOW 0xFAEAA9FF
#define COLOR_LIGHTGREEN 0x00FF00FF
#define COLOR_LIGHTORANGE 0xF7A26FFF
#define COLOR_LIGHTRED 0xFF0000FF
#define COLOR_RED 0xAA3333AA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_RED 0xAA3333AA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_YELLOW2 0xFFFF00FF
#define COLOR_ORANGE 0xFF9900AA
#define COLOR_BLUE 0xFF9900AA
#define COLOR_SYSTEM 0xEFEFF7AA
#define COLOR_PINK 0xFF66FFAA
#define SPAWN_DELAY 3000
#define COLOR_KOMENDA 0xC83322FF
#define COLOR_GRAD1 0xC83322FF
#define COLOR_WIADOMOSC 0x00FF00FF
#define COLOR_BLACK 0x000000FF
#define COLOR_ADMIN 0xFF0000AA
//========================== K O N I E C =======================================
/*public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" Blank Filterscript by your name here");
print("--------------------------------------\n");
return 1;
}
public OnFilterScriptExit()
{
return 1;
}*/
public OnGameModeInit()
{
if(dini_Exists(LEKARZ)){
}
else
{
dini_Create(LEKARZ);
}
// Don't use these lines if it's a filterscript
SetGameModeText("Blank Script");
AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
AddPlayerClass(275, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
return 1;
}
public OnGameModeExit()
{
return 1;
}
public OnPlayerRequestClass(playerid, classid)
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,258.4893,-41.4008,1002.0234);
SetPlayerFacingAngle(playerid, 270.0);
SetPlayerCameraPos(playerid,256.0815,-43.0475,1004.0234);
SetPlayerCameraLookAt(playerid,258.4893,-41.4008,1002.0234);
switch (classid)
{
case 0:
{
GameTextForPlayer(playerid, "~y~L~w~ekarze", 2000, 6);
DajDoLekarz(playerid);
gTeam[playerid] = TEAM_LEKARZ;
}
}
return 1;
}
public OnPlayerConnect(playerid)
{
ShowPlayerNameTagForPlayer(playerid,2,0); //ukrycie nicku gracza playerid dla gracza o id 2.
/*SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"------------------------------------------------------------------------------------------");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Witaj, %s na serwerze Drift King!");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Zach?camy do rejestracji na serwerze, unikniesz podszywania si?.");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Zapraszam do korzystania z unikalnych event?w drifterskich!");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Mo?esz sprawidzi? statystyki serwera na stronie: {FF0000}http://staty.d-k.net");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"{99FF00}» {00AAFF}Prosz? o przeczytanie listy komend itp: {DD0000}/cmd");
SendClientMessage(playerid, KOLOR_WEJSCIE_NA_SERWER,"------------------------------------------------------------------------------------------");*/
//Skrzynia
GearInfo[playerid] = TextDrawCreate(596.000000, 425.000000, "~w~R ~g~~h~N ~w~D");
TextDrawBackgroundColor(GearInfo[playerid], 255);
TextDrawFont(GearInfo[playerid], 1);
TextDrawLetterSize(GearInfo[playerid], 0.320000, 1.299999);
TextDrawColor(GearInfo[playerid], -1);
TextDrawSetOutline(GearInfo[playerid], 0);
TextDrawSetProportional(GearInfo[playerid], 1);
TextDrawSetShadow(GearInfo[playerid], 1);
Speedo[playerid] = TextDrawCreate(579.000000, 414.000000, "255 ~w~km/h");
TextDrawBackgroundColor(Speedo[playerid], 0x000000FF);
TextDrawFont(Speedo[playerid], 1);
TextDrawLetterSize(Speedo[playerid], 0.170000, 0.799999);
TextDrawColor(Speedo[playerid], 0xA803D0FF);
TextDrawSetOutline(Speedo[playerid], 0);
TextDrawSetProportional(Speedo[playerid], 1);
TextDrawSetShadow(Speedo[playerid], 1);
timer[playerid] = SetTimerEx("ShiftFunction",150,true,"i",playerid);
//Koniec
return 1;
}
stock GetSpeed(playerid)
{
new Float:ST[3];
GetVehicleVelocity(GetPlayerVehicleID(playerid),ST[0],ST[1],ST[2]);
return floatround(1.61*floatsqroot(floatpower(floatabs(ST[0]), 2.0) + floatpower(floatabs(ST[1]), 2.0) + floatpower(floatabs(ST[2]), 2.0)) * 100.3);
}
public OnPlayerDisconnect(playerid, reason)
{
KillTimer(timer[playerid]);
TextDrawDestroy(GearInfo[playerid]);
TextDrawDestroy(Speedo[playerid]);
return 1;
}
public OnPlayerSpawn(playerid)
{
if (gTeam[playerid] == TEAM_LEKARZ ){
new nen[256];
format(nen, 256, "[Lekarz]%s", PlayerName(playerid)); //Literka przy nicku gracza [P]
SetPlayerName(playerid, nen);
SetPlayerColor(playerid,0xFFFFFF00); //Ustawiamy kolor frakcji, policja ma niewidoczny
SendClientMessage(playerid, COLOR_LIGHTRED, "Witaj! Aby zobaczyж komendy pracownika wpisz /cmds"); //Komendy pracownika zmieniamy na swoje
//Cbstat[playerid]=9; //Kanal CB jesli jest na serwerze
}
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
if (gTeam[playerid] == TEAM_LEKARZ){
new PlayerNamex[256];
PlayerNamex = PlayerName(playerid);
if(strfind(PlayerNamex, "[Lekarz]", false)!=-1){
PlayerNamex = strreplace("[Lekarz]", "",PlayerName(playerid));
SetPlayerName(playerid, PlayerNamex);
}
}
}
public OnVehicleSpawn(vehicleid)
{
return 1;
}
public OnVehicleDeath(vehicleid, killerid)
{
return 1;
}
public OnPlayerText(playerid, text[])
{
new str[128];
if(IsPlayerAdmin(playerid))
{
format(str, sizeof str, "{99FF00}{99FF00}[ {00AAFF}%d # {FF0000}Admin {99FF00}]{FFFFFF}: %s", playerid, text);
}
else
{
format(str, sizeof str, "{99FF00}{99FF00}[ {00AAFF}%d # Gracz {99FF00}]{FFFFFF}: %s", playerid, text);
}
SendPlayerMessageToAll(playerid, str);
return false;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
return 0;
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
return 1;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
return 1;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER) cGear[GetPlayerVehicleID(playerid)]=1;
return 1;
}
public OnPlayerEnterCheckpoint(playerid)
{
return 1;
}
public OnPlayerLeaveCheckpoint(playerid)
{
return 1;
}
public OnPlayerEnterRaceCheckpoint(playerid)
{
return 1;
}
public OnPlayerLeaveRaceCheckpoint(playerid)
{
return 1;
}
public OnRconCommand(cmd[])
{
return 1;
}
public OnPlayerRequestSpawn(playerid)
{
if(gTeam[playerid] == TEAM_LEKARZ && wlekarz[playerid] == 1){
return 1;
}
else if(gTeam[playerid] == TEAM_LEKARZ && wlekarz[playerid] != 1){
return 0;
}
return 1;
}
public OnObjectMoved(objectid)
{
return 1;
}
public OnPlayerObjectMoved(playerid, objectid)
{
return 1;
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
return 1;
}
public OnVehicleMod(playerid, vehicleid, componentid)
{
return 1;
}
public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
return 1;
}
public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
return 1;
}
public OnPlayerSelectedMenuRow(playerid, row)
{
return 1;
}
public OnPlayerExitedMenu(playerid)
{
return 1;
}
public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
return 1;
}
public OnRconLoginAttempt(ip[], password[], success)
{
return 1;
}
public OnPlayerUpdate(playerid)
{
return 1;
}
public OnPlayerStreamIn(playerid, forplayerid)
{
return 1;
}
public OnPlayerStreamOut(playerid, forplayerid)
{
return 1;
}
public OnVehicleStreamIn(vehicleid, forplayerid)
{
return 1;
}
public OnVehicleStreamOut(vehicleid, forplayerid)
{
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
return 1;
}
public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
return 1;
}
forward DajDoLekarz(playerid);
public DajDoLekarz(playerid)
{
if(strval(dini_Get(LEKARZ, PlayerName(playerid))) == 1)
wlekarz[playerid] = 1;
return 1;
}stock PlayerName(playerid)
{
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
return name;
}
Ca?a mapka dzia?a poprawnie
Licz? na ---->
Wysłany: 2012-05-06, 19:54
kamil445
:D
Wiek: 29 Na forum: 6151 dni Posty: 119
Nick w MP: Czechu
Piwa : 882
Witam mam problem z tym jak ktos zaloguje sie na adma to poka?e si? na czacie ze ten ktos sie zalogowa?
mam taki kod:
Kod:
forward adminek();
public adminek(){
new string[256];
for(new xxx=0;xxx<MAX_GRACZY;xxx++){
if(IsPlayerConnected(xxx)){
if(IsPlayerAdmin(xxx) == 1 && !zalogowany[xxx]){
zalogowany[xxx] = true;
new playername[MAX_PLAYER_NAME];
GetPlayerName(xxx,playername,sizeof(playername));
format(string, sizeof(string), "%s (ID: %d) zalogowa?(a) si? jako Administrator", playername, xxx);
SendClientMessageToAll(COLOR_LIGHTBLUE, string);
SetPlayerColor(xxx, 0xFF0000AA);
SoundForAll(1133);
}
}
}
}
return 1;
)
a errory:
Kod:
error 010: invalid function or declaration
ta linika
Kod:
za pomoc
Wysłany: 2012-05-06, 20:17
BBBay
It's a Programmer
Wiek: 28 Na forum: 5428 dni Posty: 97
Nick w MP: xBBBay
Piwa : 340
Usun jedno } z przed retrun 1; .
Wysłany: 2012-05-06, 20:30
kamil445
:D
Wiek: 29 Na forum: 6151 dni Posty: 119
Nick w MP: Czechu
Piwa : 882
wtedy to mi si? mapka sypie
Kod: error 017: undefined symbol "CreatePlayerVehicle"
a to mam zdefiniowane Oo
EDIT: Ju? nie trzeba, poradzi?em sobie ;]
Wysłany: 2012-05-07, 18:40
Sillence
Wiek: 26 Na forum: 5157 dni Posty: 1514
Nick w MP: Sillence
Piwa : 1517
Usu? Kod:
Tagi: błędy :: przy :: kompilacji :: rozwiązanie
Anonymous
Na forum: 245 dni
Posty: 1
Anonymous Koniecznie zajrzyj na: