AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting (https://forums.alliedmods.net/forumdisplay.php?f=107)
-   -   [L4D2] VScripting How to Startle a Witch (https://forums.alliedmods.net/showthread.php?t=332444)

jeremyvillanueva 05-13-2021 10:18

[L4D2] VScripting How to Startle a Witch
 
Hi, I need help,
I'm trying to startle a Witch with VScript, I'm using VSLib also
PHP Code:

foreach( witch in ::VSLib.EasyLogic.Zombies.Witches() )
        {
            
local vsPlayer = ::VSLib.EasyLogic.Players.SurvivorWithHighestFlow();
            
witch.Damage(witch.GetHealth()-990vsPlayer);
            
//if ( witch.IsAlive() && Entities.FindByClassname( null, "worldspawn" ) )
            //    witch.Damage(witch.GetHealth()-99, 0, ::VSLib.Entity("worldspawn"));
            
witch.SetNetProp"m_rage"1);
            
witch.SetNetProp"m_mobRush"1);
            
//Entity(ent).BotAttack(vsPlayer);
            
witch.BotAttack(vsPlayer);
        } 

I just get the witch to get her health reduction, but she still wanders...

May you help me, please?


All times are GMT -4. The time now is 23:59.

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