Skocz do zawartości

Witamy w Nieoficjalnym polskim support'cie AMX Mod X

Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
  • Rozpoczynaj nowe tematy i odpowiedaj na inne
  • Zapisz się do tematów i for, aby otrzymywać automatyczne uaktualnienia
  • Dodawaj wydarzenia do kalendarza społecznościowego
  • Stwórz swój własny profil i zdobywaj nowych znajomych
  • Zdobywaj nowe doświadczenia

Dołączona grafika Dołączona grafika

Guest Message by DevFuse
 

Zdjęcie
CoD Nowy

Problem z He 1/1

cod nowy

  • Nie możesz napisać tematu
  • Zaloguj się, aby dodać odpowiedź
5 odpowiedzi w tym temacie

#1 Majster02

    Zaawansowany

  • Użytkownik

Reputacja: 14
Początkujący

  • Postów:101
  • GG:
Offline

Napisano 08.03.2020 19:08

Witam mam problem z klasa nie dziala He 1/1 
 

#include <amxmodx>
#include <amxmisc>
#include <codmod>
#include <fun>
#include <hamsandwich>
#include <cstrike>

#define DMG_BULLET (1<<1)
#define DMG_HEGRENADE (1<<24)

new const nazwa[]   = "Kapitan";
new const opis[]    = "1/1 z awp 1/1 z he";
new const bronie    = (1<<CSW_HEGRENADE)|(1<<CSW_AWP)|(1<<CSW_DEAGLE);
new const zdrowie   = 0;
new const kondycja  = 0;
new const inteligencja = 0;
new const wytrzymalosc = 0;

new ma_klase[33];

public plugin_init()
{
	register_plugin(nazwa, "1.0", "Alelluja");
	
	cod_register_class(nazwa, opis, bronie, zdrowie, kondycja, inteligencja, wytrzymalosc);
	
	RegisterHam(Ham_TakeDamage, "player", "Zabicie");
	register_event("ResetHUD", "ResetHUD", "abe");
}

public cod_class_enabled(id)
{
	ma_klase[id] = true;
	ResetHUD(id);
	
}

public cod_class_disabled(id)
{
	ma_klase[id] = false;
}

public Zabicie(this, idinflictor, idattacker, Float:damage, damagebits)
{
	if(!is_user_connected(idattacker))
		return HAM_IGNORED;
	
	if(!ma_klase[idattacker])
		return HAM_IGNORED;      
	
	if(get_user_team(this) != get_user_team(idattacker) && get_user_weapon(idattacker) == CSW_AWP && damagebits & DMG_BULLET && random_num(1, 1) == 1)
		cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);
	
	if(get_user_team(this) != get_user_team(idattacker) && get_user_weapon(idattacker) == CSW_HEGRENADE && damagebits & DMG_HEGRENADE && random_num(1, 1) == 1)
		cod_inflict_damage(idattacker, this, float(get_user_health(this))-damage+1.0, 0.0, idinflictor, damagebits);
	
	return HAM_IGNORED;
}

public ResetHUD(id)
{
	set_task(0.1, "ResetHUDx", id);
}

public ResetHUDx(id)
{
	if(!is_user_connected(id)) return;

	if(!ma_klase[id]) return;

	cs_set_user_bpammo(id, CSW_HEGRENADE, 2);

}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par }
*/


  • +
  • -
  • 0

#2 Deus Vult

    Nowy

  • Użytkownik

Reputacja: 109
Zaawansowany

  • Postów:213
  • GG:
  • Imię:Mateusz
  • Lokalizacja:Rzeszow
Offline

Napisano 08.03.2020 20:36

logi ?


  • +
  • -
  • 0

#3 Majster02

    Zaawansowany

  • Autor tematu
  • Użytkownik

Reputacja: 14
Początkujący

  • Postów:101
  • GG:
Offline

Napisano 08.03.2020 22:44

******************************         Login Passed... Welcome       ******************************

L 03/08/2020 - 22:42:51: Server cvar "amxmodx_version" = "1.8.2"
L 03/08/2020 - 22:42:51: Server cvar "sv_maxspeed" = "900"
[AMXX] Loaded 1 admin from file
L 03/08/2020 - 22:42:51: Server cvar "amx_language" = "en"
L 03/08/2020 - 22:42:51: Server cvar "amx_client_languages" = "1"
L 03/08/2020 - 22:42:51: Server cvar "amx_nextmap" = "de_airstrip"
Executing AMX Mod X Configuration File 
Scrolling message displaying frequency: 10:00 minutes
L 03/08/2020 - 22:42:51: Server cvar "sv_maxspeed" = "9999"
[S_API FAIL] SteamAPI_Init() failed; SteamAPI_IsSteamRunning() failed.
dlopen failed trying to load:
/data/majster07s/.steam/sdk32/steamclient.so
with error:
/data/majster07s/.steam/sdk32/steamclient.so: cannot open shared object file: No such file or directory
Looking up breakpad interfaces from steamclient
Calling BreakpadMiniDumpSystemInit
L 03/08/2020 - 22:42:51: Server cvar "sv_accelerate" = "5"
L 03/08/2020 - 22:42:51: Server cvar "sv_stopspeed" = "75"
L 03/08/2020 - 22:42:52: Started map "de_dust2" (CRC "1159425449")

L 03/08/2020 - 22:42:52: Log file closed
Server logging data to file logs/L0308007.log
L 03/08/2020 - 22:42:52: Log file started (file "logs/L0308007.log") (game "cstrike") (version "48/1.1.2.7/Stdio/1621")
L 03/08/2020 - 22:42:52: Server cvar "mp_timelimit" = "25"
L 03/08/2020 - 22:42:52: Server cvar "mp_c4timer" = "30"
L 03/08/2020 - 22:42:52: Server cvar "mp_flashlight" = "1"
L 03/08/2020 - 22:42:52: Server cvar "mp_freezetime" = "4"
L 03/08/2020 - 22:42:52: Server cvar "mp_friendlyfire" = "1"
L 03/08/2020 - 22:42:52: Server cvar "mp_hostagepenalty" = "2"
L 03/08/2020 - 22:42:52: Server cvar "mp_roundtime" = "4"
L 03/08/2020 - 22:42:52: Server cvar "mp_tkpunish" = "1"
L 03/08/2020 - 22:42:52: Server cvar "mp_chattime" = "0"
L 03/08/2020 - 22:42:52: Server cvar "sv_maxspeed" = "320"
L 03/08/2020 - 22:42:52: Server cvar "allow_spectators" = "0"
L 03/08/2020 - 22:42:52: Server cvar "decalfrequency" = "60"
couldn't exec banned.cfg
couldn't exec listip.cfg
Menu item 17 added to Menus Front-End: "Plugin Cvars" from plugin "pluginmenu.amxx"
Menu item 18 added to Menus Front-End: "Plugin Commands" from plugin "pluginmenu.amxx"
Connection to Steam servers successful.
L 03/08/2020 - 22:42:52: Server cvar "sv_maxspeed" = "9999"
   VAC secure mode is activated.
L 03/08/2020 - 22:42:57: "HLTV-test-majster07s<1><HLTV><>" connected, address "193.33.176.11:27020"
L 03/08/2020 - 22:42:58: "HLTV-test-majster07s<1><HLTV><>" entered the game
L 03/08/2020 - 22:42:58: "HLTV-test-majster07s<1><HLTV><>" joined team "SPECTATOR"
L 03/08/2020 - 22:42:59: World triggered "Round_Start"
L 03/08/2020 - 22:43:11: "MajSter<2><STEAM_1:0:542918241><>" connected, address "84.10.150.168:27005"
L 03/08/2020 - 22:43:11: [admin.amxx] Login: "MajSter<2><STEAM_1:0:542918241><>" became an admin (account "MajSter") (access "abcdefghijklmnopqrstu") (address "84.10.150.168")
ERROR: couldn't open custom.hpk.
L 03/08/2020 - 22:43:18: "MajSter<2><STEAM_1:0:542918241><>" entered the game
L 03/08/2020 - 22:43:20: "MajSter<2><STEAM_1:0:542918241><>" joined team "CT"

  • +
  • -
  • 0

#4 Rivit

    Godlike

  • Support Team

Reputacja: 1 319
Godlike

  • Postów:4 380
Offline

Napisano 08.03.2020 23:15

Spoiler

 

Popatrz jak to zostału tu zrobione. Zrób analogicznie.

 

 

 

EDIT: 

spróbuj usunac ten kawałek:

&& get_user_weapon(idattacker) == CSW_HEGRENADE

Użytkownik TibacK edytował ten post 08.03.2020 23:15

  • +
  • -
  • 0

#5 Majster02

    Zaawansowany

  • Autor tematu
  • Użytkownik

Reputacja: 14
Początkujący

  • Postów:101
  • GG:
Offline

Napisano 08.03.2020 23:33

 

Spoiler

 

Popatrz jak to zostału tu zrobione. Zrób analogicznie.

 

 

 

EDIT: 

spróbuj usunac ten kawałek:

&& get_user_weapon(idattacker) == CSW_HEGRENADE

Nadal nie dziala


  • +
  • -
  • 0

#6 Rivit

    Godlike

  • Support Team

Reputacja: 1 319
Godlike

  • Postów:4 380
Offline

Napisano 08.03.2020 23:58

ok, to przerób sobie analogicznie jak w kodzie co podałem


  • +
  • -
  • 0





Również z jednym lub większą ilością słów kluczowych: cod nowy

Użytkownicy przeglądający ten temat: 0

0 użytkowników, 0 gości, 0 anonimowych