Raised This Month: $ Target: $400
 0% 

Hook Orpheu Respawn


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
colossus
Member
Join Date: Sep 2013
Old 09-13-2013 , 01:49   Hook Orpheu Respawn
Reply With Quote #1

This code only job in the new round.

How could I use this code using a command to revive any player?

This code only works for me when new round, but not when I use for example hookea pev_deadflag ...

I would like to know how hookear to revive at any time of the round ...

Code:
/* Plugin generated by AMXX-Studio */ #include <amxmodx> #include <orpheu> #include <orpheu_stocks> #define PLUGIN "New Plug-In" #define VERSION "1.0" #define AUTHOR "colossus" public plugin_init() {     register_plugin(PLUGIN, VERSION, AUTHOR)         // Add your code here...     OrpheuRegisterHook(OrpheuGetFunctionFromClass("player","Spawn","CBasePlayer"), "CBasePlayer_Spawn") } public CBasePlayer_Spawn(id) {     }
colossus is offline
Old 09-13-2013, 01:55
dark_style
This message has been deleted by dark_style. Reason: nevermind
Old 09-13-2013, 05:52
LordOfNothing
This message has been deleted by Arkshine. Reason: Troll answer
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-13-2013 , 07:56   Re: Hook Orpheu Respawn
Reply With Quote #2

You don't need Orpheu. Just hook Ham_Spawn.
__________________
Arkshine is offline
simanovich
AlliedModders Donor
Join Date: Jun 2012
Location: Israel
Old 09-13-2013 , 08:20   Re: Hook Orpheu Respawn
Reply With Quote #3

Quote:
Originally Posted by Arkshine View Post
You don't need Orpheu. Just hook Ham_Spawn.
+1
Hamsandwich module is the best for hooking any entity spawn (include players).
__________________
simanovich is offline
colossus
Member
Join Date: Sep 2013
Old 09-13-2013 , 12:40   Re: Hook Orpheu Respawn
Reply With Quote #4

Okey.

I heard that it is better to hook Orpheu functions.
colossus is offline
dark_style
Senior Member
Join Date: Jul 2009
Location: Bulgaria
Old 09-13-2013 , 12:44   Re: Hook Orpheu Respawn
Reply With Quote #5

My deleted post was "Do you really need orpheu for this" but decided to delete it because you may have understood it as a spam. Orpheu is a cool module, it really gives more "power" to the coders but it isn't really needed to use it for such easy things, it will only make your work harder.
__________________



dark_style is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-13-2013 , 12:47   Re: Hook Orpheu Respawn
Reply With Quote #6

Don't use virtual functions with Orpheu. Ham method is more direct and thus slightly efficient. Also, it's more convenient/simple to use Ham as all is already configured.

Use Orpheu when you can't do something with others modules.
__________________
Arkshine is offline
colossus
Member
Join Date: Sep 2013
Old 09-13-2013 , 14:42   Re: Hook Orpheu Respawn
Reply With Quote #7

Woow okay. Thank you. Later I will make a thread with questions about a Orpheu code, thanks.
colossus 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 18:56.


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