[AMX] Tổng hợp Code, Plug do Mem chế hoặc giới thiệu

  • Thread starter Thread starter Orpheus
  • Ngày gửi Ngày gửi
129092786498235257.jpg
129092786498235257.jpg
 
@legiondark:
- Chuyện đó rất dễ với con hổ lai báo mang tên KungFuLon, nên cái đó nói ra nó làm dc là nó chọi gạch đấy =))
 
Phải bỏ đi cho nó giống cso, nhưng mà vẫn phải để nó trong TUT vì đấy là plugin nguyên bản của sontung mà (TUT có nói là cách thêm súng cho CSO-NST F5 đâu)

À ừ.. Rồi sau này có thằng cũng lôi cái NST_WPN chỉnh sửa cho F5 ra tống vào game của nó rồi chửi thầm tại sao không có chức sight hay melee của súng cho xem, cho nên ta vẫn đợi khi nào 1002 xong thì viết full review
01.gif
 
À ừ.. Rồi sau này có thằng cũng lôi cái NST_WPN chỉnh sửa cho F5 ra tống vào game của nó rồi chửi thầm tại sao không có chức sight hay melee của súng cho xem, cho nên ta vẫn đợi khi nào 1002 xong thì viết full review
01.gif
Bỏ mấy cái đó đi thì hết CSCF lởm luôn=))
 
@legiondark:
- Chuyện đó rất dễ với con hổ lai báo mang tên KungFuLon, nên cái đó nói ra nó làm dc là nó chọi gạch đấy =))
È, thôi kệ đê, biết tính tên này r` nên cũng chả nói :))
^
^
Thì thêm vô TUT cái dòng :1 số chức năng k thể sử dụng cho cso-nst f5: , đỡ rách việc :))
 
Các bác cho em hỏi code thay đổi uy lực, số đạn (clip & ammo), độ giật của súng mặc định với...Please!
 
^
-> Mở cái Tut hd làm thêm plugin súng mới của sontung0 ra. trong plugin cho sẵn có đó
 
có plugins weapon_max_clip về xem thử
độ giật thì :-??
 
Các bạn có plugin laser nào k?
À cái ZP làm thế nào để bỏ zom mặc định và thêm custom zombie nhỉ :D
 
^
- Mời bác qua bên thread ZP của GVN (Nhìn lên đoạn thread dc Stick là thấy) :)
 
Tặng cho mọi người cái này, cái này của 5c0r cho mình :)). Nhưng mà ko sài hoặc có thể nói là ko biết sài =))

... Này thì... Sorpack
bh_classes_v1.4.zip
Sorpack-Biohazard.rar
Update.rar
UpdatePackage.zip

*Sorpack là của Hồng Kông, và Hồng Kông ko phải "của" Tàu Khựa, xin cân nhắc :)), ai cần proof tôi sẽ cho ym của 1 người bạn ở Taipei rồi tự hỏi.
 
Chỉnh sửa cuối:
Ai Giúp hộ mình cái plug-in này với :(
Code:[spoil]
#include <amxmodx>

#define PLUGIN "Weapon Icon"
#define VERSION "1.0"
#define AUTHOR " (m$ubn)"

new iconstatus;
new user_icons[220][32];
new icon_origin[3] = {0,0,0}
new pcv_show;
new pcv_iloc;

public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)

register_event ("CurWeapon", "update_icon", "ab")
register_event("DeathMsg", "event_death", "a")
pcv_show = register_cvar("amx_show_weapon_icon", "1");
pcv_iloc = register_cvar("amx_show_weapon_icon_location", "1");
register_concmd("amx_weapon_icon", "weapon_icon_toggle", ADMIN_CVAR, "Toggle display of the weapon icon on/off (default on)")

check_icon_loc();
}

public update_icon(id) {
check_icon_loc();
if(!get_pcvar_num(pcv_show) || get_pcvar_num(pcv_iloc) == 0)
return PLUGIN_CONTINUE;

if(is_user_alive(id))
{
new iwpn, wclip, wammo, sprite[192], icon_color[3] = {255, 255, 255}

remove_weapon_icon(id)

iwpn = get_user_weapon(id, wclip, wammo)
switch(iwpn) {
case CSW_P228: sprite = "d_p228"
case CSW_SCOUT: sprite = "d_scout"
case CSW_HEGRENADE: sprite = "d_grenade"
case CSW_XM1014: sprite = "d_xm1014"
case CSW_C4: sprite = "d_c4"
case CSW_MAC10: sprite = "d_mac10"
case CSW_AUG: sprite = "d_aug"
case CSW_SMOKEGRENADE: sprite = "d_grenade"
case CSW_ELITE: sprite = "d_elite"
case CSW_FIVESEVEN: sprite = "d_fiveseven"
case CSW_UMP45: sprite = "d_ump45"
case CSW_SG550: sprite = "d_sg550"
case CSW_GALIL: sprite = "d_galil"
case CSW_FAMAS: sprite = "d_famas"
case CSW_USP: sprite = "d_usp"
case CSW_MP5NAVY: sprite = "d_mp5navy"
case CSW_M249: sprite = "d_m249"
case CSW_M3: sprite = "d_m3"
case CSW_M4A1: sprite = "m4a1c"
case CSW_TMP: sprite = "d_tmp"
case CSW_G3SG1: sprite = "d_g3sg1"
case CSW_FLASHBANG: sprite = "d_flashbang"
case CSW_DEAGLE: sprite = "d_deagle"
case CSW_SG552: sprite = "d_sg552"
case CSW_AK47: sprite = "d_ak47"
case CSW_KNIFE: sprite = "d_knife"
case CSW_P90: sprite = "d_p90"
case CSW_VEST: sprite = "suit_full"
case CSW_VESTHELM: sprite = "suithelmet_full"
case CSW_GLOCK18: sprite = "d_glock18"
case CSW_AWP: sprite = "d_awp"
case 0: sprite = ""
default: sprite = ""
}
if (is_user_ok(id)) {
if (equali(sprite, "") || !is_user_ok(id)) {
remove_weapon_icon(id)
} else {
// draw the sprite itself (only on a human user's screen)
// marker ////////////////////////////////////////////////////////////////////////////////
message_begin(MSG_ONE,iconstatus,icon_origin,id);
write_byte(1); // status (0=hide, 1=show, 2=flash)
write_string(sprite); // sprite name

/*
4 stages - Normal, 1 Clip, No Clip + Some ammo, Completely Out

*/

// ammo check, this is for the color of the icon
get_user_ammo(id, iwpn, wammo, wclip) // update vars correctly
if (wclip == 0 && wammo == 0) icon_color = {0, 0, 255} // outta ammo!
if (wclip == wammo || wclip > wammo) icon_color = {255, 150, 150} // last clip!
if (wammo > 0 && wclip == 0) icon_color = {255, 100, 100} // almost out!
// attempt at percentage max clip & % red/green color
// 1: Get max ammo for weapon
//maxammo = maxclip(iwpn);


write_byte(icon_color[0]); // red
write_byte(icon_color[1]); // green
write_byte(icon_color[2]); // blue
message_end();
}
user_icons[id] = sprite;
}
}
return PLUGIN_CONTINUE
}

public weapon_icon_toggle(id) {
new toggle[32], players[32], num, player, status[32] = "enabled"
read_argv(1, toggle, 1)

if (equali(toggle, "1")) {
status = "enabled"
} else if (equali(toggle, "0")) {
status = "disabled"
} else if (equali(toggle, "")) {
console_print(id, "Usage: amx_weapon_icon <1/0> - Toggles wether or not showing the user's current weapon as an icon")
console_print(id, "Weapon Icon is currently %s", status)
return PLUGIN_HANDLED
}

set_cvar_string("amx_show_weapon_icon", toggle)
client_print(0, print_chat, "Weapon Icon is now %s", status)
get_players(players, num)
for (new i=0; i<num; i++) {
player = players
if (!equali(user_icons[player], "") && !equali(players, "") && is_user_ok(id)) {
remove_weapon_icon(i)
}
}
return PLUGIN_CONTINUE
}

public remove_weapon_icon(id) {
if (is_user_ok(id)) {
message_begin(MSG_ONE,iconstatus,icon_origin,id);
write_byte(0);
write_string(user_icons[id]);
message_end();
}
}

public is_user_ok(id) {
// check if the user is "ok": they are connected, not a bot, and alive
if (is_user_connected(id) && !is_user_bot(id) && is_user_alive(id))
return true
return false
}

public event_death() {
new player = read_data(2) // the dead player's ID (1-32)
if (is_user_connected(player) && !is_user_bot(player)) { // remove icon
message_begin(MSG_ONE,iconstatus,icon_origin,player);
write_byte(0);
write_string(user_icons[player]);
message_end();
}
}

public check_icon_loc() {
if(!get_pcvar_num(pcv_iloc))
return PLUGIN_CONTINUE;
new value = get_pcvar_num(pcv_iloc);
if (value == 0)
iconstatus = 0;
if (value == 1)
iconstatus = get_user_msgid("StatusIcon");
if (value == 2)
iconstatus = get_user_msgid("Scenario");
return PLUGIN_CONTINUE;
}
[/spoil]
Mình muốn chuyển chỗ của weapon icon sang chỗ khác thì sửa code ntn bây giờ (Hay là sprites :-o nhi)
Hình VD:untitled.PNG
 
Ai Giúp hộ mình cái plug-in này với :(
Code:[spoil]
#include <amxmodx>

#define PLUGIN "Weapon Icon"
#define VERSION "1.0"
#define AUTHOR " (m$ubn)"

new iconstatus;
new user_icons[220][32];
new icon_origin[3] = {0,0,0}
new pcv_show;
new pcv_iloc;

public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)

register_event ("CurWeapon", "update_icon", "ab")
register_event("DeathMsg", "event_death", "a")
pcv_show = register_cvar("amx_show_weapon_icon", "1");
pcv_iloc = register_cvar("amx_show_weapon_icon_location", "1");
register_concmd("amx_weapon_icon", "weapon_icon_toggle", ADMIN_CVAR, "Toggle display of the weapon icon on/off (default on)")

check_icon_loc();
}

public update_icon(id) {
check_icon_loc();
if(!get_pcvar_num(pcv_show) || get_pcvar_num(pcv_iloc) == 0)
return PLUGIN_CONTINUE;

if(is_user_alive(id))
{
new iwpn, wclip, wammo, sprite[192], icon_color[3] = {255, 255, 255}

remove_weapon_icon(id)

iwpn = get_user_weapon(id, wclip, wammo)
switch(iwpn) {
case CSW_P228: sprite = "d_p228"
case CSW_SCOUT: sprite = "d_scout"
case CSW_HEGRENADE: sprite = "d_grenade"
case CSW_XM1014: sprite = "d_xm1014"
case CSW_C4: sprite = "d_c4"
case CSW_MAC10: sprite = "d_mac10"
case CSW_AUG: sprite = "d_aug"
case CSW_SMOKEGRENADE: sprite = "d_grenade"
case CSW_ELITE: sprite = "d_elite"
case CSW_FIVESEVEN: sprite = "d_fiveseven"
case CSW_UMP45: sprite = "d_ump45"
case CSW_SG550: sprite = "d_sg550"
case CSW_GALIL: sprite = "d_galil"
case CSW_FAMAS: sprite = "d_famas"
case CSW_USP: sprite = "d_usp"
case CSW_MP5NAVY: sprite = "d_mp5navy"
case CSW_M249: sprite = "d_m249"
case CSW_M3: sprite = "d_m3"
case CSW_M4A1: sprite = "m4a1c"
case CSW_TMP: sprite = "d_tmp"
case CSW_G3SG1: sprite = "d_g3sg1"
case CSW_FLASHBANG: sprite = "d_flashbang"
case CSW_DEAGLE: sprite = "d_deagle"
case CSW_SG552: sprite = "d_sg552"
case CSW_AK47: sprite = "d_ak47"
case CSW_KNIFE: sprite = "d_knife"
case CSW_P90: sprite = "d_p90"
case CSW_VEST: sprite = "suit_full"
case CSW_VESTHELM: sprite = "suithelmet_full"
case CSW_GLOCK18: sprite = "d_glock18"
case CSW_AWP: sprite = "d_awp"
case 0: sprite = ""
default: sprite = ""
}
if (is_user_ok(id)) {
if (equali(sprite, "") || !is_user_ok(id)) {
remove_weapon_icon(id)
} else {
// draw the sprite itself (only on a human user's screen)
// marker ////////////////////////////////////////////////////////////////////////////////
message_begin(MSG_ONE,iconstatus,icon_origin,id);
write_byte(1); // status (0=hide, 1=show, 2=flash)
write_string(sprite); // sprite name

/*
4 stages - Normal, 1 Clip, No Clip + Some ammo, Completely Out

*/

// ammo check, this is for the color of the icon
get_user_ammo(id, iwpn, wammo, wclip) // update vars correctly
if (wclip == 0 && wammo == 0) icon_color = {0, 0, 255} // outta ammo!
if (wclip == wammo || wclip > wammo) icon_color = {255, 150, 150} // last clip!
if (wammo > 0 && wclip == 0) icon_color = {255, 100, 100} // almost out!
// attempt at percentage max clip & % red/green color
// 1: Get max ammo for weapon
//maxammo = maxclip(iwpn);


write_byte(icon_color[0]); // red
write_byte(icon_color[1]); // green
write_byte(icon_color[2]); // blue
message_end();
}
user_icons[id] = sprite;
}
}
return PLUGIN_CONTINUE
}

public weapon_icon_toggle(id) {
new toggle[32], players[32], num, player, status[32] = "enabled"
read_argv(1, toggle, 1)

if (equali(toggle, "1")) {
status = "enabled"
} else if (equali(toggle, "0")) {
status = "disabled"
} else if (equali(toggle, "")) {
console_print(id, "Usage: amx_weapon_icon <1/0> - Toggles wether or not showing the user's current weapon as an icon")
console_print(id, "Weapon Icon is currently %s", status)
return PLUGIN_HANDLED
}

set_cvar_string("amx_show_weapon_icon", toggle)
client_print(0, print_chat, "Weapon Icon is now %s", status)
get_players(players, num)
for (new i=0; i<num; i++) {
player = players
if (!equali(user_icons[player], "") && !equali(players, "") && is_user_ok(id)) {
remove_weapon_icon(i)
}
}
return PLUGIN_CONTINUE
}

public remove_weapon_icon(id) {
if (is_user_ok(id)) {
message_begin(MSG_ONE,iconstatus,icon_origin,id);
write_byte(0);
write_string(user_icons[id]);
message_end();
}
}

public is_user_ok(id) {
// check if the user is "ok": they are connected, not a bot, and alive
if (is_user_connected(id) && !is_user_bot(id) && is_user_alive(id))
return true
return false
}

public event_death() {
new player = read_data(2) // the dead player's ID (1-32)
if (is_user_connected(player) && !is_user_bot(player)) { // remove icon
message_begin(MSG_ONE,iconstatus,icon_origin,player);
write_byte(0);
write_string(user_icons[player]);
message_end();
}
}

public check_icon_loc() {
if(!get_pcvar_num(pcv_iloc))
return PLUGIN_CONTINUE;
new value = get_pcvar_num(pcv_iloc);
if (value == 0)
iconstatus = 0;
if (value == 1)
iconstatus = get_user_msgid("StatusIcon");
if (value == 2)
iconstatus = get_user_msgid("Scenario");
return PLUGIN_CONTINUE;
}
[/spoil]
Mình muốn chuyển chỗ của weapon icon sang chỗ khác thì sửa code ntn bây giờ (Hay là sprites :-o nhi)
Hình VD:View attachment 142269
 
Ai Giúp hộ mình cái plug-in này với :(
Code:[spoil]
#include <amxmodx>

#define PLUGIN "Weapon Icon"
#define VERSION "1.0"
#define AUTHOR " (m$ubn)"

new iconstatus;
new user_icons[220][32];
new icon_origin[3] = {0,0,0}
new pcv_show;
new pcv_iloc;

public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)

register_event ("CurWeapon", "update_icon", "ab")
register_event("DeathMsg", "event_death", "a")
pcv_show = register_cvar("amx_show_weapon_icon", "1");
pcv_iloc = register_cvar("amx_show_weapon_icon_location", "1");
register_concmd("amx_weapon_icon", "weapon_icon_toggle", ADMIN_CVAR, "Toggle display of the weapon icon on/off (default on)")

check_icon_loc();
}

public update_icon(id) {
check_icon_loc();
if(!get_pcvar_num(pcv_show) || get_pcvar_num(pcv_iloc) == 0)
return PLUGIN_CONTINUE;

if(is_user_alive(id))
{
new iwpn, wclip, wammo, sprite[192], icon_color[3] = {255, 255, 255}

remove_weapon_icon(id)

iwpn = get_user_weapon(id, wclip, wammo)
switch(iwpn) {
case CSW_P228: sprite = "d_p228"
case CSW_SCOUT: sprite = "d_scout"
case CSW_HEGRENADE: sprite = "d_grenade"
case CSW_XM1014: sprite = "d_xm1014"
case CSW_C4: sprite = "d_c4"
case CSW_MAC10: sprite = "d_mac10"
case CSW_AUG: sprite = "d_aug"
case CSW_SMOKEGRENADE: sprite = "d_grenade"
case CSW_ELITE: sprite = "d_elite"
case CSW_FIVESEVEN: sprite = "d_fiveseven"
case CSW_UMP45: sprite = "d_ump45"
case CSW_SG550: sprite = "d_sg550"
case CSW_GALIL: sprite = "d_galil"
case CSW_FAMAS: sprite = "d_famas"
case CSW_USP: sprite = "d_usp"
case CSW_MP5NAVY: sprite = "d_mp5navy"
case CSW_M249: sprite = "d_m249"
case CSW_M3: sprite = "d_m3"
case CSW_M4A1: sprite = "m4a1c"
case CSW_TMP: sprite = "d_tmp"
case CSW_G3SG1: sprite = "d_g3sg1"
case CSW_FLASHBANG: sprite = "d_flashbang"
case CSW_DEAGLE: sprite = "d_deagle"
case CSW_SG552: sprite = "d_sg552"
case CSW_AK47: sprite = "d_ak47"
case CSW_KNIFE: sprite = "d_knife"
case CSW_P90: sprite = "d_p90"
case CSW_VEST: sprite = "suit_full"
case CSW_VESTHELM: sprite = "suithelmet_full"
case CSW_GLOCK18: sprite = "d_glock18"
case CSW_AWP: sprite = "d_awp"
case 0: sprite = ""
default: sprite = ""
}
if (is_user_ok(id)) {
if (equali(sprite, "") || !is_user_ok(id)) {
remove_weapon_icon(id)
} else {
// draw the sprite itself (only on a human user's screen)
// marker ////////////////////////////////////////////////////////////////////////////////
message_begin(MSG_ONE,iconstatus,icon_origin,id);
write_byte(1); // status (0=hide, 1=show, 2=flash)
write_string(sprite); // sprite name

/*
4 stages - Normal, 1 Clip, No Clip + Some ammo, Completely Out

*/

// ammo check, this is for the color of the icon
get_user_ammo(id, iwpn, wammo, wclip) // update vars correctly
if (wclip == 0 && wammo == 0) icon_color = {0, 0, 255} // outta ammo!
if (wclip == wammo || wclip > wammo) icon_color = {255, 150, 150} // last clip!
if (wammo > 0 && wclip == 0) icon_color = {255, 100, 100} // almost out!
// attempt at percentage max clip & % red/green color
// 1: Get max ammo for weapon
//maxammo = maxclip(iwpn);


write_byte(icon_color[0]); // red
write_byte(icon_color[1]); // green
write_byte(icon_color[2]); // blue
message_end();
}
user_icons[id] = sprite;
}
}
return PLUGIN_CONTINUE
}

public weapon_icon_toggle(id) {
new toggle[32], players[32], num, player, status[32] = "enabled"
read_argv(1, toggle, 1)

if (equali(toggle, "1")) {
status = "enabled"
} else if (equali(toggle, "0")) {
status = "disabled"
} else if (equali(toggle, "")) {
console_print(id, "Usage: amx_weapon_icon <1/0> - Toggles wether or not showing the user's current weapon as an icon")
console_print(id, "Weapon Icon is currently %s", status)
return PLUGIN_HANDLED
}

set_cvar_string("amx_show_weapon_icon", toggle)
client_print(0, print_chat, "Weapon Icon is now %s", status)
get_players(players, num)
for (new i=0; i<num; i++) {
player = players
if (!equali(user_icons[player], "") && !equali(players, "") && is_user_ok(id)) {
remove_weapon_icon(i)
}
}
return PLUGIN_CONTINUE
}

public remove_weapon_icon(id) {
if (is_user_ok(id)) {
message_begin(MSG_ONE,iconstatus,icon_origin,id);
write_byte(0);
write_string(user_icons[id]);
message_end();
}
}

public is_user_ok(id) {
// check if the user is "ok": they are connected, not a bot, and alive
if (is_user_connected(id) && !is_user_bot(id) && is_user_alive(id))
return true
return false
}

public event_death() {
new player = read_data(2) // the dead player's ID (1-32)
if (is_user_connected(player) && !is_user_bot(player)) { // remove icon
message_begin(MSG_ONE,iconstatus,icon_origin,player);
write_byte(0);
write_string(user_icons[player]);
message_end();
}
}

public check_icon_loc() {
if(!get_pcvar_num(pcv_iloc))
return PLUGIN_CONTINUE;
new value = get_pcvar_num(pcv_iloc);
if (value == 0)
iconstatus = 0;
if (value == 1)
iconstatus = get_user_msgid("StatusIcon");
if (value == 2)
iconstatus = get_user_msgid("Scenario");
return PLUGIN_CONTINUE;
}
[/spoil]
Mình muốn chuyển chỗ của weapon icon sang chỗ khác thì sửa code ntn bây giờ (Hay là sprites :-o nhi)
Hình VD:View attachment 142269


Metahook thẳng tiến:|
 
Metahook thẳng tiến:|
Bạn chỉ rõ cho mình được không :| Thấy mọi người bảo metahook làm được Score Board,Hud,bla,bla....:D Nhưng mình không thấy link download nó ở đâu :( Trên google thì nó bảo metahook ở đâu đâu ý :(
 
Vs những người new programer thì họ có thể hiểu nổi code của mh hay ko :-/
Nếu họ chịu khó tìm tòi thì chả có gì là khó cả:-"
 
Đợi họ tìm xong chắc cũng hết mùa quít =)) Cần cù rất tốt nhưng nếu thiếu tư duy cũng bằng 0 =))
 
^
Thằng nào cũng được như ông thì :
- Đếch bao giờ có TUT
- Đếch bao giờ phải học hỏi
- Đếch bao giờ phải lên forum. ^:)^
 
tìm khoảng vài tháng là ok ...

List các ngôn ngữ lập trình chưa học xong =]]:
Pawn AMX
Pascal
AutoIT
In progress:
C
C++
 
Chỉnh sửa cuối:
Back
Top