[AMX][Codes] Hỏi đáp về các code của AMX ...

  • Thread starter Thread starter sontung0
  • Ngày gửi Ngày gửi
Status
Không mở trả lời sau này.
là sao , tui chơi Zombie Plague :| , cần fụ gì hok :-S , con PC làm xong chưa ?
 
ý tôi nói cùng chung về evolution nhưng code của Bio khác của sontung
 
ý tôi nói cùng chung về evolution nhưng code của Bio khác của sontung

cái zombie mod ở sign cậu làm sao mà cầm dc nhìu súng to 1 lúc vậy
là bug hay do cố ý
nếu cố ý thì nó có ổn định hơn plugin cầm nhìu súng trên alliedmod ko
 
đang chơi bị văng ra màn hình desktop ko báo nguyên nhân có thể do những lỗi gì hả các bác ? có cách nào check KO ?
 
Cái lỗi quái quỷ thế này mà không ai bít hết ah
[video]zui7lupPzaw[/video]!

Khi làm spectator thì thấy hand không bị lỗi gì hết!
Vậy là sao trời !
@NST: Cậu cũng tịt lun à ??=((
 
Chắc đụng plugins rồi chứ gì :|
 
chả bít đụng cái nào , đang kt từng cái :)) , ông bị bao giờ chưa ?
 
cái zombie mod ở sign cậu làm sao mà cầm dc nhìu súng to 1 lúc vậy
là bug hay do cố ý
nếu cố ý thì nó có ổn định hơn plugin cầm nhìu súng trên alliedmod ko

Multi weapon hoặc cũng có thể nó dùng weapon pack :-?

mrkun nói:
chả bít đụng cái nào , đang kt từng cái , ông bị bao giờ chưa ?

Vứt cái plugin-zplague.ini và cái plugin.ini ra cho mọi người xem. Show vào trong thẻ quote đi
 
Multi weapon hoặc cũng có thể nó dùng weapon pack :-?



Vứt cái plugin-zplague.ini và cái plugin.ini ra cho mọi người xem. Show vào trong thẻ quote đi

bít cái multi weapon rùi nhưng nó bị lỗi ko có backpack ammo ở súng phụ
còn cái weapon pack là cái je`
 
[ZP]Weapon pack.. Khi mua nó sẽ cho 1 đống thứ linh tinh 8-}.. Mua 1 nhát được mấy khẩu primary, lục và bom =)). Hồi trước server tôi trên Garena, tôi làm 1 cuộc thống kê tại server mình và thấy rằng 70% các bố không chọn ở menu súng của ZP mà mua ngay item đấy được 1 đống súng lỉnh khỉnh bắn qua ngày =)). Có thằng bệnh đến nối bắn hết súng này súng khác mà quên nạp đạn, lúc zombie đuổi rút các súng ra nạp ---> Xác định đê
01.gif
 
plugins.ini

; Custom - Add 3rd party plugins here
;statsx.amxx
ultimate_chat.amxx // ng` chết chat ng` sống thấy đc
weaponphys.amxx // hiệu ứng vật lý
headshot.amxx // fát âm thanh headshot + hud "Headshot"
Bullet_Whizz.amxx // âm thanh tia đạn
weapon_lights.amxx // ánh sáng khi bắn
advanced_weapon_tracers.amxx // tia đạn
lie_flat.amxx // hịu ứng cho weapon khi nắm trên mặt fẳng nghiêng
buyzonerange.amxx // xóa buyzone
zombie_plague40.amxx debug // hí hí
bullet_damage_ranking.amxx // show damage
norecoilsilencer.amxx // gắn silencer >> no recoil
Damage_Control.amxx // set damage cho từng súng
damage_effect.amxx // hịu ứng khi bị zombie cào

plugins-zplague.ini

; Add sub-plugins, custom zombie classes, and extra items here

zp_addon_displaymode.amxx // hiện mode đang chơi
zp_corpse.amxx // măm măm
APchange.amxx // hiện số ammo thay đổi + âm thanh
zp_countdown_remix.amxx // 3...2....1.....á á á
zp_radio.amxx // radio cho zombie
zp_sub_rewards.amxx // thưởng cho mỗi loại kill
zp_extra_fastrun.amxx // nhấn B tăng tốc cho Human


; Classes :

zp_zclass_smoker.amxx // ai cũng bít rùi
zp_zclass_tight10c.amxx // ai cũng bít rùi
zp_zclass_regeneration.amxx // ai cũng bít rùi
zp_zclass_nurse.amxx // hồi máu cho zombie xong wanh
zp_zclass_scientist.amxx // tỉ lệ gây mù cho human
zp_zclass_siren.amxx // ai cũng bít rùi
zp_zclass_iron.amxx // bị bắn chỉ mất 1 máu
zp_zclass_witch.amxx // ai cũng bít rùi
zp_zclass_slayer.amxx debug // chuột fải kill human
zp_zcls_leap.amxx // leap liên tù tì
zp_zcls_ghost.amxx // đứng xa tàng hình , lại gần mờ mờ , F1 mất tích
zp_zcls_hunter.amxx debug // F1 fóng
zp_zclass_vampire.amxx debug // hút máu khi cào trúng human
zp_zombie_respawn.amxx debug // chết hồi sinh , headshot >>> go to the hell
zp_zclass_surgeon.amxx debug // cào human tỉ lệ làm human rớt súng

; Items :

zp_extra_human_armor.amxx // armor
zp_extra_radar.amxx // radar cho human
zp_extra_lasermine.amxx // ...
zp_extra_pipe.amxx // ...
Zp_Extra_NST_ASVAL.amxx // NST_weapon
Zp_Extra_NST_G36C.amxx // NST_weapon
Zp_Extra_NST_CV47.amxx // NST_weapon
Zp_Extra_NST_stalker.amxx // NST_weapon
Zp_Extra_NST_Sm4a1.amxx // NST_weapon
Zp_Extra_NST_Sawnoff_Shotgun.amxx // ....
Zp_Extra_NST_BerrettaM82.amxx // NST_weapon
zp_extra_minigun.amxx //..........
zp_extra_bazooka.amxx //........

zp_morehp.amxx // mua hp cho zombie
zp_extra_conc.amxx // bom lú @@
zp_extra_snark.amxx debug // con bọ
 
Chỉnh sửa cuối:
; Custom - Add 3rd party plugins here
;statsx.amxx
ultimate_chat.amxx // ng` chết chat ng` sống thấy đc
weaponphys.amxx // hiệu ứng vật lý
headshot.amxx // fát âm thanh headshot + hud "Headshot"
Bullet_Whizz.amxx // âm thanh tia đạn
weapon_lights.amxx // ánh sáng khi bắn
advanced_weapon_tracers.amxx // tia đạn
lie_flat.amxx // hịu ứng cho weapon khi nắm trên mặt fẳng nghiêng
buyzonerange.amxx // xóa buyzone
zombie_plague40.amxx debug // hí hí
bullet_damage_ranking.amxx // show damage
norecoilsilencer.amxx // gắn silencer >> no recoil
Damage_Control.amxx // set damage cho từng súng
damage_effect.amxx // hịu ứng khi bị zombie cào

Sao cái zp.amxx lại để vào đây X_X
 
ủa lúc mới cài tui để vào đó rùi :D , hùi đó ko bị , mới bị dạo gần đây , nhưng ko để ý nên chả bít do plugin nào :))

ông coi hộ tui mấy class zombie ý , tui nghĩ do bọn nó , đang thử disable zombie class , thấy chưa bị văng :))
 
Ai cho đoạn code Random class zombie trong ZP Nào
 
Mấy bác xem hộ code class ghost cho bio với:

Tự dưng chọn class thì bị lây nhiễm die luôn. Chọn mấy class kia thì bình thường.
chọn ghost là tự dưng die

PHP:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <biohazard>
#include <hamsandwich>
#include <engine>
#include <fun>

#define PLUGIN "Bio Ghost Zombie"
#define VERSION "1.0"
#define AUTHOR "Sophia - Dias"

#define D_ZOMBIE_NAME "Ghost Zombie"
#define D_ZOMBIE_DESC "F1 - Invisible"
#define D_PLAYER_MODEL "models/player/bio_ghost-zombie/bio_ghost-zombie.mdl"
#define D_CLAWS "models/bio/v_knife_ghost.mdl"

new g_ghost
new Float:g_first_time[33]
new i_first_time_hud[33]
new i_cooldown_time[33]
new g_cooldown[33]
new g_infections[33]
new Float:g_ghost_cooldown_standart = 20.0
new Float:g_first_time_standart = 10.0

public plugin_init()
{
	register_plugin(PLUGIN, VERSION, AUTHOR)
	is_biomod_active() ? plugin_init2() : pause("ad")
	register_clcmd("ability1", "use_ability_one")
	register_concmd("ability1", "use_ability_one")
	register_forward(FM_PlayerPreThink, "fw_PlayerPreThink")
	RegisterHam(Ham_TakeDamage, "player", "fw_TakeDamage")
	register_logevent("roundStart", 2, "1=Round_Start")
}

public plugin_precache()
{
precache_model(D_PLAYER_MODEL)
precache_model(D_CLAWS)
}

public plugin_init2()
{
	g_ghost = register_class(D_ZOMBIE_NAME, D_ZOMBIE_DESC)
	
	if(g_ghost != -1)
	{
		set_class_data(g_ghost, DATA_HEALTH, 800.0)
		set_class_data(g_ghost, DATA_BONUS, 10.0)
		set_class_data(g_ghost, DATA_ARMOR, 50.0)
		set_class_data(g_ghost, DATA_SPEED, 255.0)
		set_class_data(g_ghost, DATA_GRAVITY, 0.7)
		set_class_data(g_ghost, DATA_ATTACK, 0.1)
		set_class_data(g_ghost, DATA_HITDELAY, 0.1)
		set_class_data(g_ghost, DATA_HITREGENDLY, 999.0)
		set_class_data(g_ghost, DATA_KNOCKBACK, 0.8)
		set_class_pmodel(g_ghost, D_PLAYER_MODEL)
		set_class_wmodel(g_ghost, D_CLAWS)
	}
	
}

public use_ability_one(id)
{
	if(is_valid_ent(id) && is_user_alive(id) && is_user_zombie(id) && get_user_class(id) == g_ghost)
	{
		if(g_cooldown[id] == 0)
		{
			set_user_rendering(id, kRenderFxGlowShell, 0, 0, 0, kRenderTransAlpha, 0)
			set_task(g_first_time[id],"ghost_make_visible",id)
			set_task(g_ghost_cooldown_standart,"reset_cooldown",id)
			g_cooldown[id] = 1
			i_cooldown_time[id] = floatround(g_ghost_cooldown_standart)
			i_first_time_hud[id] = floatround(g_first_time[id])
			
			set_task(1.0, "ShowHUD", id, _, _, "a",i_cooldown_time[id])
			set_task(1.0, "ShowHUDstealthes", id, _, _, "a",i_first_time_hud[id])
		}
	}
}

public ShowHUDstealthes(id)
{
	if(is_valid_ent(id) && is_user_alive(id))
	{
		i_first_time_hud[id] = i_first_time_hud[id] - 1;
		set_hudmessage(200, 100, 0, -1.0, 0.92, 0, 1.0, 1.1, 0.0, 0.0, -1)
		show_hudmessage(id, "Time: %d",i_first_time_hud[id])
	}else{
		remove_task(id)
	}
}

public ghost_make_visible(id)
{
	if(is_valid_ent(id) && is_user_zombie(id) && get_user_class(id) == g_ghost)
	{
		set_user_rendering(id, kRenderFxHologram, 0, 0, 0, kRenderTransAlpha, 125)
	}
}

public reset_cooldown(id)
{
	if(is_valid_ent(id) && is_user_zombie(id) && get_user_class(id) == g_ghost)
	{
		g_cooldown[id] = 0
		
		new text[100]
		format(text,99,"^x04[ZP]^x01 Your ability ^x04Stealth^x01 is ready.")
		message_begin(MSG_ONE,get_user_msgid("SayText"),{0,0,0},id) 
		write_byte(id) 
		write_string(text) 
		message_end()
	}
}

public event_infect(id, infector)
{
	if ((get_user_class(id) == g_ghost))
	{
		set_user_rendering(id, kRenderFxHologram, 0, 0, 0, kRenderTransAlpha, 125)
		
		new text[100]
		new note_cooldown = floatround(g_ghost_cooldown_standart)
		new note_stealthtime = floatround(g_first_time_standart)
		format(text,99,"^x04[ZP]^x01 Your ability is ^x04Stealth^x01. Cooldown:^x04 %d ^x01seconds. Stealth time: ^x04%d^x01 seconds.",note_cooldown,note_stealthtime)
		message_begin(MSG_ONE,get_user_msgid("SayText"),{0,0,0},id) 
		write_byte(id) 
		write_string(text) 
		message_end()
		
		i_cooldown_time[id] = floatround(g_ghost_cooldown_standart)
		remove_task(id)
		
		g_first_time[id] = g_first_time_standart
		g_cooldown[id] = 0
		g_infections[id] = 0
		
		client_cmd(id,"bind F1 ability1")
	}
	
	if((get_user_class(infector) == g_ghost))
	{
		g_first_time[infector] = g_first_time[infector] + 1;
		infections_hud(infector)
	}
}		

public roundStart(id)
{
	set_user_rendering(id, kRenderFxNone, 0, 0, 0, kRenderTransAlpha, 255)
	remove_task(id)
}

public infections_hud(id)
{
	if(is_valid_ent(id) && is_user_zombie(id) && get_user_class(id) == g_ghost)
	{
		new i_first_time = floatround(g_first_time[id])
		new text[100]
		format(text,99,"^x04[ZP]^x01 Your stealth time is^x04 %d ^x01seconds.",i_first_time)
		message_begin(MSG_ONE,get_user_msgid("SayText"),{0,0,0},id) 
		write_byte(id) 
		write_string(text) 
		message_end() 
	}
}

public fw_TakeDamage(victim, inflictor, attacker, Float:damage, damage_type)
{
	if (!(damage_type & DMG_FALL) || !is_user_zombie(victim) || get_user_class(victim) != g_ghost)
		return HAM_IGNORED
	
	SetHamParamFloat(4, 0.0)
	return HAM_HANDLED
}

public fw_PlayerPreThink(player)
{
	if(!is_user_alive(player))
		return FMRES_IGNORED
		
	if(is_user_zombie(player) && get_user_class(player) == g_ghost)
		set_pev(player, pev_flTimeStepSound, 999)
		
	return FMRES_IGNORED
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1049\\ f0\\ fs16 \n\\ par }
*/

P/S: Mrkun cho cái ym nào. ;)) có gì thảo luận cho dễ
 
class này có trên AM mà , sao lại ghi AUTHOR tên ông thế kia =.= , à ra là cho Bio ,:-SS thế thì tui ko rành =))

làm đc random class chưa ?
 
@mrkun
làm dc random class tôi chết ngay cho ông xem =))
 
nhìn trong cái zombie class menu tui đưa bên AM đó , chỉ cần dùng /* */ vài chỗ là đc , tui mới làm hùi chìu , chưa bít có fát sinh lỗi gì ko nữa :))
 
Status
Không mở trả lời sau này.
Back
Top