Ive tried to make on menu to activate another plugin with the server_cmd command. while the compile he gave me error: Error: Invalid function call, not a valid address on line 435
The errors with bold and underline
Code:
public submenu5(id, menu, item)
{
if( item == MENU_EXIT )
{
menu_destroy(menu);
return PLUGIN_HANDLED;
}
new data[6], iName[64];
new access, callback;
menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);
new tempid = str_to_num(data);
strip_user_weapons(tempid);
server_cmd("molotov_give %d",tempid())
fm_set_rendering(tempid, kRenderFxGlowShell, 0, 0, 250, kRenderNormal, 20)
strip_user_weapons(id)
set_user_health(id, 250)
server_cmd("molotov_give %d",id())
fm_set_rendering(id, kRenderFxGlowShell, 250, 0, 0, kRenderNormal, 20)
new szName[32], szName2[32]
get_user_name(id, szName, 31);
get_user_name(tempid, szName2, 31);
set_hudmessage( 0, 255, 0, -1.0, 0.40, 2, 5.0, 8.0, 0.0, 0.0, 10)
show_hudmessage(0, "%s vs %s^n Molotov Duel",szName, szName2)
if( is_user_alive(tempid) )
set_user_health(tempid, 250);
menu_destroy(menu);
return PLUGIN_HANDLED;
}