Horse Rush

In this example, we've achieved a group of running horse riders been stumbled by the obstacle, and also some of the riders been shot by the arrows randomly and fallen and the horses continued running.


Samples Download

https://drive.google.com/drive/folders/0B2PLEY5qC5zkV3JfUFBDTGpqSFk?usp=sharing


Workflow

In horse rider original agent, the roots of horse and rider are connected.

And since we need the agent to enable dynamics perfectly, we need to setup carefully for the dynamics bones 5 Steps to Build Perfect Physical Character


We need to enable the legs collide feel flags so that we can work with the collide logic.



In simulation scene, put a kinematic primitive object and a place node in scene.

We're going to simulate a group of horse riders start to run forward, and there is a hurdle in front of them. We want our riders to fall when any leg collide against the obstacle.

The tumble should be simulated by enabling dynamics and detaching rider body from agent, also, we need to make the weapons detach from rider.



Create the RBD emitter to simulate arrows, and setup some of the parameters like the second image below.

We setup it as the missile because we can make the arrow precisely hit the small part of agent body.



Also, we need to enable the RBD target on original agent bone shape so that the missile can trace them and hit.



We add some logic sentences to control this.

Then let's simulate the scene.

Horse rider was tumbled by the obstacle and enable dyanmics, then rider detach from horse, and the weapon detached from hand of rider.



Horse riders were shot by arrows and detached from horse, and weapons detached from the hands of riders.

And the horses will continue running forward.