Can you explain this line !
Код:
new n = find_ent_by_target(-1,"fire_button_texture")
Your plugin failed to compile!Код:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2013 ITB CompuPhase, AMX Mod X Team
botton.sma(22) : error 017: undefined symbol "find_ent_by_target"
botton.sma(50) : warning 203: symbol is never used: "n"
1 Error.
Could not locate output file botton.amx (compile failed).
plugin In the new situation
Код:
#include <amxmodx>
#include <hamsandwich>
#include <fakemeta>
#define PLUGIN "Use Buttons"
#define VERSION "0.1"
#define AUTHOR "euro-hl.6f.sk"
new ehlBombMsg
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
RegisterHam(Ham_Touch,"trigger_multiple","_trigger_multiple",1)
}
public _trigger_multiple(const iEntity, const id)
{
new n = find_ent_by_target(-1,"fire_button_texture")
if (iEntity == n ) ////NUKEBUTTON
{
if (is_user_alive(id))
{
new msg[64]
get_pcvar_string(ehlBombMsg, msg, charsmax(msg))
//
if (msg[0]) // Check if is set bomb message
{
new name[32]
get_user_name(id, name, charsmax(name))
set_hudmessage(0, 255, 0, 0.75, 0.83, 0, 6.0, 10.0)
show_hudmessage(0, msg, name)
}
}
else
{
set_hudmessage(255, 0, 0, 0.65, 0.83, 0, 6.0, 10.0)
show_hudmessage(0, "Plugin by [euro-hl.6f.sk]")
}
}
}