As requested by White Dragon, this is a very, VERY old demo of how you could make vehicle riding modes once upon a time. It's so simple though that ugly code aside you can still make some use of it today for a straight forward ride/run/whatever mode. Keep in mind though, it IS outdated, so make sure to ask if this is the right thing for you.
The horse is nothing more than a none type entity with the galloping animation for its idle. It runs the following script on its update event. At the time the only way - and to this day an effective, albeit crude method:
One modification you might try is to bind the Y location to parent entity's base rather than just 0. This would make it dynamically adapt to stages more where the base position isn't 0. Mid stage base changes wouldn't look great, but if things are getting that complex you're progressing beyond a quick and easy solution..
DC
The horse is nothing more than a none type entity with the galloping animation for its idle. It runs the following script on its update event. At the time the only way - and to this day an effective, albeit crude method:
C:
void main()
{
void self = getlocalvar("self");
void parent = getentityproperty(self, "parent");
float x = getentityproperty(parent, "x");
float z = getentityproperty(parent, "z");
float a = getentityproperty(parent, "a");
changeentityproperty(self, "position", x, z-2, 0);
}
One modification you might try is to bind the Y location to parent entity's base rather than just 0. This would make it dynamically adapt to stages more where the base position isn't 0. Mid stage base changes wouldn't look great, but if things are getting that complex you're progressing beyond a quick and easy solution..
DC