Raised This Month: $ Target: $400
 0% 

RegisterHamFromEntity sends incorrectly


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
hlstriker
Green Gaben
Join Date: Mar 2006
Location: OH-IO!
Old 05-15-2009 , 11:08   Re: RegisterHamFromEntity sends incorrectly
Reply With Quote #4

From hamsandwich.inc:
PHP Code:
/**
 * Hooks the virtual table for the specified entity's class.
 * An example would be: RegisterHam(Ham_TakeDamage, id, "player_hurt");
 * Look at the Ham enum for parameter lists.
 * Note: This will cause hooks for the entire internal class that the entity is
 *       not exclusively for the provided entity.
 *
 * @param function        The function to hook.
 * @param EntityId        The entity classname to hook.
 * @param callback        The forward to call.
 * @param post            Whether or not to forward this in post.
 * @return                 Returns a handle to the forward.  Use EnableHamForward/DisableHamForward to toggle the forward on or off.
 */
native HamHook:RegisterHamFromEntity(Ham:function, EntityId, const Callback[], Post=0); 
So, it does make more sense to use RegisterHam() if you already know your entities classname.
hlstriker is offline
 



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 01:30.


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