Raised This Month: $ Target: $400
 0% 

how to use RegisterHam


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
President
Member
Join Date: May 2013
Old 06-09-2013 , 12:22   Re: how to use RegisterHam
Reply With Quote #8

PHP Code:
RegisterHam(Ham_*, "entity's_classname""Name_Of_Function"1); // 1 - after forward execute
RegisterHam(Ham_*, "entity's_classname""Name_Of_Function"0); // 0 - before forward execute
RegisterHam(Ham_*, "entity's_classname""Name_Of_Function"); // nothing - before forward execute


register_touch("classname_1""classname_2""Name_Of_Function");
// Example: register_touch("weaponbox", "player", "Player_touchs_Weapon");
// this touch will be executed when the player touch the weapon
// sth you have to know: when entity1 touch entity2, entity2 touch entity1, so the forward is executed 2 times


register_think("classname""Name_Of_Function");


register_forward(FM_CmdStart"fwdcmdstart");
// generally executed when player press any key ( both mouse and keyboard :D )


// Use register_think() and register_touch() instead of registering forwards FM_Think and FM_Touch.
// They are much faster.
// However not everything in engine is faster than fakemeta 
President 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 16:13.


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