Skidanje hp i armora istovremeno

Započeo Sonicc, April 13, 2020, 21:54:39 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Problem(error/warning): Dok se igraci pucaju istovremeno im se skida i hp i armor
Dio skripte: trenutno nemam posaljem ako bude trebalo
Debug iz server_log(ukoliko je u pitanju crashanje servera - crashdetect log): [ code ]vaš odgovor[ /code ]
Slika/video ingame problema(obavezno ako je ingame problem): link slike nemam sliku posaljem ako je potrebno

new Float:WeaponDamage[ 43 ][ 7 ] = {
   {5.0, 15.0, 2.0, 2.0, 7.0, 7.0, 20.0}, // Unarmed
   {10.0, 15.0, 15.0, 22.0, 22.0, 22.0, 30.0},// Brass Knuckles
   {15.0, 25.0, 5.0, 5.0, 7.0, 7.0, 35.0},// Golf Club
   {25.0, 25.0, 7.0, 7.0, 10.0, 10.0, 30.0},// Night Stick
   {40.0, 50.0, 15.0, 15.0, 17.0, 17.0, 60.0},// Knife
   {15.0, 25.0, 5.0, 5.0, 7.0, 7.0, 35.0},// Baseball Bat
   {15.0, 25.0, 5.0, 5.0, 7.0, 7.0, 35.0},// Shovel
   {10.0, 50.0, 5.0, 5.0, 17.0, 17.0, 10.0},// Pool Cue
   {50.0, 55.0, 25.0, 25.0, 27.0, 27.0, 100.0},// Katana
   {70.0, 75.0, 50.0, 50.0, 60.0, 60.0, 100.0},// Chainsaw
   {10.0, 50.0, 5.0, 5.0, 7.0, 7.0, 50.0}, // dildo
   {10.0, 50.0, 5.0, 5.0, 7.0, 7.0, 50.0}, // dildo
   {10.0, 50.0, 5.0, 5.0, 7.0, 7.0, 50.0}, // dildo
   {10.0, 50.0, 5.0, 5.0, 7.0, 7.0, 50.0}, // dildo
   {5.0, 5.0, 1.0, 1.0, 5.0, 5.0, 10.0}, // Flowers
   {10.0, 50.0, 5.0, 5.0, 7.0, 7.0, 50.0}, // Cane
   {100.0, 100.0, 50.0, 50.0, 60.0, 60.0, 100.0},// Grenade
   {5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0}, // Tear Gas
   {70.0, 80.0, 20.0, 20.0, 30.0, 30.0, 100.0}, // Molotov
   {70.0, 80.0, 20.0, 20.0, 30.0, 30.0, 100.0},//"Invalid Weapon",
   {70.0, 80.0, 20.0, 20.0, 30.0, 30.0, 100.0},//"Invalid Weapon",
   {70.0, 80.0, 20.0, 20.0, 30.0, 30.0, 100.0},//"Invalid Weapon",
   {35.0, 50.0, 15.0, 15.0, 17.0, 17.0, 100.0}, // Colt 45
   {35.0, 50.0, 15.0, 15.0, 17.0, 17.0, 100.0}, // Silenced Colt 45
   {55.0, 60.0, 25.0, 25.0, 27.0, 27.0, 100.0}, // Desert Eagle
   {90.0, 80.0, 35.0, 35.0, 47.0, 47.0, 100.0}, // Shotgun
   {90.0, 80.0, 35.0, 35.0, 47.0, 47.0, 100.0}, // Sawno-ff Shotgun
   {90.0, 80.0, 35.0, 35.0, 47.0, 47.0, 100.0}, // Combat Shotgun
   {70.0, 80.0, 25.0, 25.0, 27.0, 27.0, 100.0}, // Micro SMG
   {80.0, 80.0, 30.0, 30.0, 35.0, 35.0, 100.0}, // SMG
   {80.0, 80.0, 40.0, 40.0, 45.0, 45.0, 100.0}, // AK47
   {80.0, 80.0, 40.0, 40.0, 45.0, 45.0, 100.0}, // M4
   {70.0, 80.0, 25.0, 25.0, 27.0, 27.0, 100.0}, // Tec9
   {80.0, 80.0, 30.0, 30.0, 35.0, 35.0, 100.0}, // Country Rifle
   {100.0, 100.0, 100.0, 100.0, 100.0, 100.0, 100.0}, // Sniper Rifle
   {100.0, 100.0, 100.0, 100.0, 100.0, 100.0, 100.0}, // Rocket Launcher
   {100.0, 100.0, 100.0, 100.0, 100.0, 100.0, 100.0}, // HS Rocket Launcher
   {70.0, 80.0, 20.0, 20.0, 30.0, 30.0, 100.0}, // Flamethrower
   {70.0, 80.0, 20.0, 20.0, 30.0, 30.0, 100.0}, // Minigun
   {100.0, 100.0, 50.0, 50.0, 60.0, 60.0, 100.0},// Satchel Charge
   {0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},// Detonator
   {10.0, 5.0, 5.0, 5.0, 5.0, 5.0, 15.0}, // Spray Can
   {10.0, 5.0, 5.0, 5.0, 5.0, 5.0, 15.0} // Fire Extinguisher
};
Obrisi ovo
Poslednja Izmena: April 13, 2020, 22:16:45 POSLE PODNE od slash dev

Hvala to sam sredio ali mi se sada hp puni kada ga pogodim tek nakon nekoliko puta se isprazni


Odakle bih to trebao ubaciti? molim te budi malo detaljniji novi sam u ovome  ::)

Citat: Sonicc poslato April 14, 2020, 01:54:23 PRE PODNE
Odakle bih to trebao ubaciti? molim te budi malo detaljniji novi sam u ovome  ::)
Pre svega nauci da koristis Google searchuj weapon config i vidi sta je

Znam što je to neg to mogu samo preuzet sa interneta ne treba mi ništa više?

ubacio sam ali imam erora mozes li mi tu pomoci?
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(1774) : warning 202: number of arguments does not match definition
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(1798) : warning 202: number of arguments does not match definition
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : error 017: undefined symbol "FreezeSyncPacket"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : warning 215: expression has no effect
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : error 001: expected token: ";", but found ")"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : error 029: invalid expression, assumed zero
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : fatal error 107: too many error messages on one line

Compilation aborted.

Pawn compiler 3.10.4	 	 	Copyright (c) 1997-2006, ITB CompuPhase

Citat: Sonicc poslato April 14, 2020, 02:47:36 PRE PODNE
ubacio sam ali imam erora mozes li mi tu pomoci?
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(1774) : warning 202: number of arguments does not match definition
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(1798) : warning 202: number of arguments does not match definition
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : error 017: undefined symbol "FreezeSyncPacket"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : warning 215: expression has no effect
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : error 001: expected token: ";", but found ")"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : error 029: invalid expression, assumed zero
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\weapon-config.inc(2217) : fatal error 107: too many error messages on one line

Compilation aborted.

Pawn compiler 3.10.4	 	 	Copyright (c) 1997-2006, ITB CompuPhase

Update sky include i plugin

Upsio sam ali sada imam opet nove errore
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\YSI\y_hooks/impl.inc(2337) : error 021: symbol already defined: "OnPlayerTakeDamage"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\YSI\y_hooks/impl.inc(2384) : error 021: symbol already defined: "OnPlayerGiveDamage"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\GetVehicleColor.inc(127) : warning 201: redefinition of constant/macro (symbol "AddStaticVehicle")
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\GetVehicleColor.inc(128) : warning 201: redefinition of constant/macro (symbol "AddStaticVehicleEx")
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\GetVehicleColor.inc(129) : warning 201: redefinition of constant/macro (symbol "CreateVehicle")
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\GetVehicleColor.inc(130) : warning 201: redefinition of constant/macro (symbol "DestroyVehicle")
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20562) : error 021: symbol already defined: "IsMeleeWeapon"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20700) : error 017: undefined symbol "weaponid"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20728) : error 017: undefined symbol "weaponid"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20734) : error 017: undefined symbol "weaponid"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(28994) : error 029: invalid expression, assumed zero
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(28994) : error 001: expected token: ";", but found "{"

Upsio sam za sada smanjiti errore
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\YSI\y_hooks/impl.inc(2337) : error 021: symbol already defined: "OnPlayerTakeDamage"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\YSI\y_hooks/impl.inc(2384) : error 021: symbol already defined: "OnPlayerGiveDamage"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20704) : error 029: invalid expression, assumed zero
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20704) : warning 215: expression has no effect
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20704) : error 001: expected token: ";", but found ")"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20704) : error 029: invalid expression, assumed zero
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(20704) : fatal error 107: too many error messages on one line

Dakle ne znam odakle bi izbriso definiciju prva dva errora
#define weaponid

public OnPlayerDamage(&playerid, &Float:amount, &issuerid, &weapon, &bodypart) {

	if( issuerid != INVALID_PLAYER_ID && issuerid != INVALID_PLAYER_ID && amount == 0 && weaponid == 0 && bodypart == 3 ) {
	    format( globalstring, sizeof( globalstring ), "{009DFF}- {FFFFFF}.:: Crown ::.{009DFF} -"col_white" %s je kickovan sa servera. Razlog: "col_white"Command kill", ImeIgraca( issuerid ) );
		AdminPoruka( SCBOJA, globalstring );
		Kickovanje( issuerid, ""col_white"Ti si kickovan sa servera. Razlog: "col_scboja"Command kill");
       	return 0;
	}

I što vamo nije u redu?


Eto je
#define weaponid

[20704]public OnPlayerDamage(&playerid, &Float:amount, &issuerid, &weapon, &bodypart) {

	if( issuerid != INVALID_PLAYER_ID && issuerid != INVALID_PLAYER_ID && amount == 0 && weaponid == 0 && bodypart == 3 ) {
	    format( globalstring, sizeof( globalstring ), "{009DFF}- {FFFFFF}.:: Crown ::.{009DFF} -"col_white" %s je kickovan sa servera. Razlog: "col_white"Command kill", ImeIgraca( issuerid ) );
		AdminPoruka( SCBOJA, globalstring );
		Kickovanje( issuerid, ""col_white"Ti si kickovan sa servera. Razlog: "col_scboja"Command kill");
       	return 0;
	}


Hvala uspio sam i ostalo mi je jos ovo
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\YSI\y_hooks/impl.inc(2337) : error 021: symbol already defined: "OnPlayerTakeDamage"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\pawno\include\YSI\y_hooks/impl.inc(2384) : error 021: symbol already defined: "OnPlayerGiveDamage"
C:\Users\M\Desktop\[CF-RP]GameMode\Uređivanje GameModa!\gamemodes\crown.pwn(28998) : warning 217: loose indentation

OnGameModeInit();
	[28998]SetVehiclePassengerDamage(true);
	SetDisableSyncBugs(true);