Raised This Month: $ Target: $400
 0% 

block bomb damage? possible?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Owyn
Veteran Member
Join Date: Nov 2007
Old 03-14-2009 , 12:36   block bomb damage? possible?
Reply With Quote #1

i tried ham_takedamage to block all damage on flagged user and return supercode but it blocked all trigger damage and fall damage but not the bomb one )= why?
Owyn is offline
Send a message via ICQ to Owyn
Dores
Veteran Member
Join Date: Jun 2008
Location: You really don't wanna k
Old 03-14-2009 , 13:04   Re: block bomb damage? possible?
Reply With Quote #2

You can remove the bomb when it explodes and create a fake exploding animation (with sound).
__________________
O o
/Ż________________________
| IMMA FIRIN' MAH LAZOR!!!
\_ŻŻŻ
Dores is offline
Owyn
Veteran Member
Join Date: Nov 2007
Old 03-14-2009 , 13:05   Re: block bomb damage? possible?
Reply With Quote #3

i don't want all players to block bomb damage, just one
Owyn is offline
Send a message via ICQ to Owyn
Dores
Veteran Member
Join Date: Jun 2008
Location: You really don't wanna k
Old 03-14-2009 , 13:06   Re: block bomb damage? possible?
Reply With Quote #4

You can kill everyone around the explosion area except for the wanted player.
__________________
O o
/Ż________________________
| IMMA FIRIN' MAH LAZOR!!!
\_ŻŻŻ
Dores is offline
Owyn
Veteran Member
Join Date: Nov 2007
Old 03-14-2009 , 13:09   Re: block bomb damage? possible?
Reply With Quote #5

and what about people not so far from bomb but which should not be killed but be damaged?
Owyn is offline
Send a message via ICQ to Owyn
Dores
Veteran Member
Join Date: Jun 2008
Location: You really don't wanna k
Old 03-14-2009 , 13:13   Re: block bomb damage? possible?
Reply With Quote #6

You need to use the calculation of distance and damage.
The farther the player, the least damage.
If the player is close, give him high damage.

There are many plugins who use that calculation, search.

P.S: Something like this:

PHP Code:
// From Molotov Cocktail plugin.
tempdmg damage - (damage range) * get_distance_f(originpOrigin); 
__________________
O o
/Ż________________________
| IMMA FIRIN' MAH LAZOR!!!
\_ŻŻŻ
Dores is offline
Hunter-Digital
Veteran Member
Join Date: Aug 2006
Location: In the Game [ro]
Old 03-14-2009 , 13:19   Re: block bomb damage? possible?
Reply With Quote #7

or you can just set that player godmode for one second while the bomb explodes...
__________________
Hunter-Digital is offline
Dores
Veteran Member
Join Date: Jun 2008
Location: You really don't wanna k
Old 03-14-2009 , 13:26   Re: block bomb damage? possible?
Reply With Quote #8

Yeah I guess that will work.
__________________
O o
/Ż________________________
| IMMA FIRIN' MAH LAZOR!!!
\_ŻŻŻ
Dores is offline
Owyn
Veteran Member
Join Date: Nov 2007
Old 03-14-2009 , 14:19   Re: block bomb damage? possible?
Reply With Quote #9

how do i make player godmode right before explosion?
Owyn is offline
Send a message via ICQ to Owyn
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 03-14-2009 , 14:26   Re: block bomb damage? possible?
Reply With Quote #10

When you detect the bomb explosion, you can use this stock:
Code:
// VEN stock fm_cs_get_grenade_type(index) {     if (get_pdata_int(index, 96, 4) & (1<<8))         return CSW_C4;         new bits = get_pdata_int(index, 114, 4);     if (bits & (1<<0))         return CSW_HEGRENADE;     else if (bits & (1<<1))         return CSW_SMOKEGRENADE;     else if (!bits)         return CSW_FLASHBANG;         return 0; }
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] 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 08:56.


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