Raised This Month: $ Target: $400
 0% 

[TF2] Destorying obj in radius


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Michalplyoutube
Veteran Member
Join Date: Jan 2013
Location: Tank Carrier in Mannhatt
Old 01-30-2015 , 07:05   [TF2] Destorying obj in radius
Reply With Quote #1

So the code that I have for player I would like to someone help me turn it to destory enemy only buildings

Code:
    for(new i=1; i<=MaxClients; i++)
    {
        if(i != client && IsPlayerAlive(i) && GetClientTeam(i) != iTeam)
        {
            if(!TF2_IsPlayerInCondition(i, TFCond_Ubercharged))
            {
                new Float:flPos2[3];
                GetClientAbsOrigin(i, flPos2);
                
                new Float:flDistance = GetVectorDistance(flPos1, flPos2);
                if(flDistance < 105)
                {
                    SDKHooks_TakeDamage(i, 0, client, 99999.0, DMG_CRUSH|DMG_ALWAYSGIB);
                    //SDKHooks_TakeDamage(i, 0, client, 99999.0, DMG_PREVENT_PHYSICS_FORCE|DMG_CRUSH|DMG_ALWAYSGIB);
                }
            }
        }
    }
Thank you
__________________
The plugin developer of TF2BWR Reborn
And a TF2 Player
Michalplyoutube 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 00:12.


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