Raised This Month: $ Target: $400
 0% 

how to execute a forward


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Porta0123
Member
Join Date: Apr 2014
Location: Spain
Old 07-09-2014 , 13:51   how to execute a forward
Reply With Quote #1

hi, i want to execute a forward called "neo_class_enabled" i want execute when player use amx_test

my first think was use "ExecuteForward" but i dont know how to execute it without the name of the file,
i have this forward in one .ini but i dont know how to execute it...
Porta0123 is offline
Black Rose
Veteran Member
Join Date: Feb 2011
Location: Stockholm, Sweden
Old 07-09-2014 , 14:06   Re: how to execute a forward
Reply With Quote #2

You can send the forward to all plugins using CreateMultiForward() to set up a forward and then execute it using ExecuteForward().

(Simple) Example:
Code:
#include <amxmodx> new hForward; public plugin_init() {     hForward = CreateMultiForward("neo_class_enabled", ET_IGNORE, FP_CELL);     register_clcmd("amx_test", "clcmdTest"); } public clcmdTest(id) {     new ret;     ExecuteForward(hForward, ret, id) }
__________________

Last edited by Black Rose; 07-09-2014 at 14:16.
Black Rose is offline
Porta0123
Member
Join Date: Apr 2014
Location: Spain
Old 07-10-2014 , 08:29   Re: how to execute a forward
Reply With Quote #3

Thanks
Porta0123 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 21:10.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode