I have created a bot that just stands in one spot and does nothing, but if you go a character with the ability to move the bot (knockback) he stays in the position he was knocked to. How do I make it so whenever the bot is knocked away from his standing position, he walks his way back and stops where he started
rule("Bot Moves Back to Start Position")
{
event
{
Player Received Knockback;
All;
All;
}
conditions
{
Is Dummy Bot(Event Player) == True;
}
actions
{
Start Throttle In Direction(Event Player, Direction Towards(Position Of(Event Player), Vector(100, 100, 100)), 1, To World,
Replace existing throttle, Direction and Magnitude);
Wait Until(Distance Between(Position Of(Event Player), Vector(100, 100, 100)) <= 0.500, 99999);
Stop Throttle In Direction(Event Player);
}
}
Replace the Position Vector (100,100,100) with the Position the Bot should go. Replace it in the Wait Until Distance Check too!
1 Like