ExecuteHamB(Ham_CS_RoundRespawn, victim)
Why doesn't the respawn on my plugin work? When i die nothing happens..
PHP Code:
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
Add a delay.
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
How? im new at coding ..just been doing it for like a week
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
Instead of adding delay you can do this:
PHP Code:
PHP Code:
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
Adding on to Sylwester's fix, the fourth parameter for RegisterHam is the post or pre call. If you have it as 0 (default), it will be called on pre (before the actual event happens). If you make it 1, it will be called on post (after the actual event).
You'd use pre for things like superceding on TakeDamage to prevent damage from happening. If you'd tried to supercede in TakeDamage post, nothing would happen, since the damage was already dealt. There are different uses for each, but for your method, as Sylwester showed you, you need to use post. |
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
Register as post (as already said), or supercede in pre, if you don't want DeathMsg being sent for example.
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
Sorry connor.. But could you explain better? .. I'm not a good coder.. im a beginner.. This is the biggest thing ive ever made
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
@ Connor:
Will supercede in pre block the victim from dying to? Example: PHP Code:
PHP Code:
|
Re: ExecuteHamB(Ham_CS_RoundRespawn, victim)
solved already .. i made this:
PHP Code:
|
| All times are GMT -4. The time now is 05:22. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.