Raised This Month: $12 Target: $400
 3% 

|ZP| Zombie Class - knockback


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Krtola
Veteran Member
Join Date: Oct 2013
Location: Serbia
Old 10-19-2014 , 08:02   |ZP| Zombie Class - knockback
Reply With Quote #1

I need a simple zombie class which will be immune on attack of certain humans.

What is meant "certain humans"?

That is humans who buy specific extra item that is declared with "g_superhuman"

So,when g_superhuman attack that zombie class he does not get knockback.

Can someone give me an example for this knockback code.

EDIT: sorry wrong section. I wanted to be in
Suggestions / Requests

Last edited by Krtola; 10-19-2014 at 08:04.
Krtola is offline
Send a message via Skype™ to Krtola
Decak
Senior Member
Join Date: Sep 2012
Old 10-19-2014 , 08:22   Re: |ZP| Zombie Class - knockback
Reply With Quote #2

if gsuperhuman[attacker] (bool) return handled
else
knock back code
Decak is offline
Krtola
Veteran Member
Join Date: Oct 2013
Location: Serbia
Old 10-19-2014 , 08:31   Re: |ZP| Zombie Class - knockback
Reply With Quote #3

Quote:
Originally Posted by Decak View Post
if gsuperhuman[attacker] (bool) return handled
else
knock back code
I know that,but where to put it?

I need a concrete example

public *****_*****
Krtola is offline
Send a message via Skype™ to Krtola
Decak
Senior Member
Join Date: Sep 2012
Old 10-19-2014 , 08:36   Re: |ZP| Zombie Class - knockback
Reply With Quote #4

Ham TakeDamage
Decak is offline
Krtola
Veteran Member
Join Date: Oct 2013
Location: Serbia
Old 10-19-2014 , 09:39   Re: |ZP| Zombie Class - knockback
Reply With Quote #5

Quote:
Originally Posted by Decak View Post
Ham TakeDamage
You mean this:

PHP Code:
public fw_TakeDamage(victiminflictorattackerFloat:damage)  

Krtola is offline
Send a message via Skype™ to Krtola
Decak
Senior Member
Join Date: Sep 2012
Old 10-19-2014 , 10:18   Re: |ZP| Zombie Class - knockback
Reply With Quote #6

Yeah.
Decak is offline
RateX
Veteran Member
Join Date: Jun 2012
Location: 0o. SEA .o0
Old 10-19-2014 , 11:06   Re: |ZP| Zombie Class - knockback
Reply With Quote #7

@Decak:
First:
Quote:
if gsuperhuman[attacker] (bool) return handled
This is ham forward, so the return value is HAM_SUPERCEDE in order to block it.
Second, doing so will cause the zombie to not recieve the damage inflicted by superhuman.
You should atleast do some reading before you post anything.
@Krtola:
In the knockback code in Request section I posted, do this:
PHP Code:
if(is_user_zombie(victim)) 

PHP Code:
if(is_user_zombie(victim) && (zp_get_user_zombie_class(victim) != zp_get_zombie_class_id("name_of_your_zombieclass"))) 
Also, you should post directly in your superhuman thread in Request section.

Last edited by RateX; 10-19-2014 at 11:07.
RateX is offline
Decak
Senior Member
Join Date: Sep 2012
Old 10-19-2014 , 11:10   Re: |ZP| Zombie Class - knockback
Reply With Quote #8

I give only an example -_-
Decak 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 09:53.


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