Raised This Month: $ Target: $400
 0% 

Returns from Fake Forwards


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 04-08-2009 , 17:03   Re: Returns from Fake Forwards
Reply With Quote #1

Okay so I was trying some code for this:
Code:
#include <amxmodx> #include <amxmisc> new g_forward1; new g_forward2; public plugin_init() {     register_plugin("Forward Test Sender", "0.1", "Exolent");         register_clcmd("say /forward", "CmdForward"); } public plugin_natives() {     register_library("forward_test");         g_forward1 = CreateMultiForward("my_forward1", ET_IGNORE);     g_forward2 = CreateMultiForward("my_forward2", ET_STOP); } public CmdForward() {     new ret;     for( new i = 0; i < 5; i++ )     {         ExecuteForward(g_forward1, ret);         log_amx("Return1 [%i / 5]: %i", i + 1, ret);                 ExecuteForward(g_forward2, ret);         log_amx("Return2 [%i / 5]: %i", i + 1, ret);     } }
Code:
#include <amxmodx> #include <amxmisc> #if AMXX_VERSION_NUM >= 175     #pragma reqlib "forward_test"     #if !defined AMXMODX_NOAUTOLOAD         #pragma loadlib "forward_test"     #endif #else     #pragma library "forward_test" #endif forward my_forward1(); forward my_forward2(); public plugin_init() {     register_plugin("Forward Test Receiver", "0.1", "Exolent"); } public my_forward1() {     static count;     count++;     log_amx("Forward1: return %i;", count);     return count; } public my_forward2() {     static count;     count++;     log_amx("Forward2: return %i;", count);     return count; }
Here is the output in my console:
Code:
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return1 [1 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return2 [1 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return1 [2 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return2 [2 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return1 [3 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return2 [3 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return1 [4 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return2 [4 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return1 [5 / 5]: 0
L 04/08/2009 - 16:03:15: [forward_test_sender.amxx] Return2 [5 / 5]: 0
There are no logs from forward_test_receive.amxx

amxx plugins
Code:
 [ 28] Forward Test Sender     0.1         Exolent           forward_test_se  running  
 [ 29] Forward Test Receiver   0.1         Exolent           forward_test_re  running
So both are running, there are no errors in my console, and I'm using AMXX 1.8.1

Where is the problem?
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] 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 02:20.


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