Raised This Month: $ Target: $400
 0% 

return PLUGIN_HANDLED


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Votorx
Senior Member
Join Date: Jun 2004
Old 08-29-2004 , 12:24   return PLUGIN_HANDLED
Reply With Quote #1

I've always wondered, what exactly is the difference between

return PLUGIN_HANDLED
return PLUGIN_CONTINUE
and
return PLUGIN_MAIN_HANDLED ...or whatever it is.
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
johnjg75
Veteran Member
Join Date: Mar 2004
Location: Delaware
Old 08-29-2004 , 12:57  
Reply With Quote #2

Code:
return PLUGIN_HANDLED
halts the plugin from going any further and
Code:
return PLUGIN_COUNTIUE
tells it to keep going. I never heard of
Code:
return PLUGIN_MAIN_HANDLED
somebody else will need to clarify that.
__________________
johnjg75 is offline
Send a message via AIM to johnjg75 Send a message via MSN to johnjg75 Send a message via Yahoo to johnjg75
Votorx
Senior Member
Join Date: Jun 2004
Old 08-29-2004 , 16:44  
Reply With Quote #3

My bad, it's actually return PLUGIN_HANDLED_MAIN (defined as 3)

Anyways can you give me an situation when you would want to use PLUGIN_CONTINUE and PLUGIN_HANDLED? Not an actual plugin just like a small example of when to use it, because I think that's my biggest problems with my plugins (unless it really doesn't matter)
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
Freecode
Never Fall Asleep
Join Date: Jan 2004
Old 08-29-2004 , 16:49  
Reply With Quote #4

PLUGIN_CONTINUE stops the current function but plugin keeps going. My explanation isnt exactly good but i tried making it as n00by as possible
Freecode is offline
Votorx
Senior Member
Join Date: Jun 2004
Old 08-29-2004 , 17:06  
Reply With Quote #5

-.- I know what it does I just want a situation when you would want to use it.
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
devicenull
Veteran Member
Join Date: Mar 2004
Location: CT
Old 08-29-2004 , 17:25  
Reply With Quote #6

in a "say"
continue, other players will see it normally
handled, no one sees the message
handled_main... I have yet to see a plugin that uses this, I dont have a clue
__________________
Various bits of semi-useful code in a bunch of languages: http://code.devicenull.org/
devicenull is offline
Votorx
Senior Member
Join Date: Jun 2004
Old 08-29-2004 , 17:28  
Reply With Quote #7

Ahhh I C, could you block a event like this?
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
devicenull
Veteran Member
Join Date: Mar 2004
Location: CT
Old 08-29-2004 , 17:30  
Reply With Quote #8

Some of them yes, others cant be blocked like this.. but like 90% can
__________________
Various bits of semi-useful code in a bunch of languages: http://code.devicenull.org/
devicenull is offline
Greenberet
AMX Mod X Beta Tester
Join Date: Apr 2004
Location: Vienna
Old 08-29-2004 , 18:51  
Reply With Quote #9

You cant block an event with this, to block an event us must use the function

set_msg_block(iMessage, iMessageFlags);

this function is in egnine module.
Greenberet is offline
Send a message via ICQ to Greenberet Send a message via MSN to Greenberet
Freecode
Never Fall Asleep
Join Date: Jan 2004
Old 08-29-2004 , 19:04  
Reply With Quote #10

Quote:
Originally Posted by Greenberet
You cant block an event with this, to block an event us must use the function

set_msg_block(iMessage, iMessageFlags);

this function is in egnine module.
matter of fact yes u can
Freecode 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 17:19.


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