Character Sinks in the ground when walk motion is applied


https://forum.reallusion.com/Topic324774.aspx
Print Topic | Close Window

By Discount Play Market - 7 Years Ago
I created a stage using props which is higher in lever then the terrain. When I apply the "left click on character" walk motion, the character will sink in the ground to the original terrain level. I made sure foot contact is checked, and I converted the prop stage to terrain, but it has not solved the issue. 
By billwright - 7 Years Ago
I am having the exact same issue.using iClone 7

By Cary B - 7 Years Ago
I had this issue with custom "personas" I had created in 3dXchange.  These custom "right-click" perform motions are scripted in lua, and can be edited in notepad. If you first "export" the persona, you can access the lua text created and edit it.

The problem I have found in the scripts is that they use a SampleTransform command of "Snap", which I believe is causing the character to snap to the grid. The older lua scripts in Iclone 6 used a SampleTransform command of "Normal", which didn't cause this problem. What I did was to open the lua script in notepad, used the "replace all" command to change all the instances of Snap to Normal. Then I could import this script back into the character persona and that solved the problem. Somebody like Rampa can probably explain it better. Ideally RL will get this changed back to use the Normal command instead of Snap. 
By Discount Play Market - 7 Years Ago
Whoa, that's a little over my head, but thanks for the reply lol
By kungphu - 7 Years Ago
I had a similar issue recently and I just kinda took a dumbed down brute force approach and did a select all and moved the set lower to line up with the floor (the terrain). Then foot contact was then OK.
By Discount Play Market - 7 Years Ago
Thanks Kungphu
By colour - 7 Years Ago
Same applies to iC prev Versions.. Characters automatically follow a Terrain. Adding the Stage to Terrain, should  fix it. If not, Import a Dummy Plane.to Stage & add that to Terrain & have Character walk-along it.. 

Right-click on Stage/Add to Terrain. See iC5 Screenshot.

https://forum.reallusion.com/uploads/images/7ef3f419-820c-4c40-89d2-b633.jpg
By billwright - 7 Years Ago
Exported the lua script - iColne 7 and looked - the Simple Transforms are all 'Normal' yet the avatar still sinks to the terrain level

By Cary B - 7 Years Ago
Yeah, sorry, I didn't explain it well.It's not as complicated as I made it sound. I'm definitely no kind of programmer. But most of my Iclone sets have multi levels, and I also have a lot of flying characters, so just lowering the set wouldn't work for me. However, if you just drag and drop motions onto the character instead of using the right-click perform function, you bypass the problem
By Cary B - 7 Years Ago
Did you re-import the new lua script back into the character? It still retains the old script until you do. 
By billwright - 7 Years Ago
Tried both things - added my house with porch to terrain.
Avatar still sinks to original terrain level insted of staying up on the porch.
I then added a floor at the height of the porch added it to terrain and turned off visiblility.
Still the same result  = avatar sinks to the original terrain level.
I am stuck

By Cary B - 7 Years Ago
If you simply drag and drop a motion onto the character do you have the same problem? 
By colour - 7 Years Ago
billwright (10/13/2017)
Tried both things - added my house with porch to terrain.
Avatar still sinks to original terrain level insted of staying up on the porch.
I then added a floor at the height of the porch added it to terrain and turned off visiblility.
Still the same result  = avatar sinks to the original terrain level.
I am stuck



See iC5 Screenshot. I replicated same prob, when applying Character Walk Forward Motion. Character drops from Deckhouse deck, to Terrain below.
SOLUTION.

At Frame 1. Right-click on Character / Remove all Animation. Apply Walk Forward Motion. Character remains on deck.

https://forum.reallusion.com/uploads/images/e477f5c4-0394-43ef-9888-87ed.jpg




By billwright - 7 Years Ago
I'll try that

By billwright - 7 Years Ago
Tried it and I stll get the same results - are these the wrong steps?
https://forum.reallusion.com/uploads/images/4cd6dbdd-d537-4606-89f5-5567.jpg
https://forum.reallusion.com/uploads/images/a92e01be-b55b-4ba6-84cb-a411.jpg
https://forum.reallusion.com/uploads/images/deccee09-773a-4f85-970b-539b.jpg
By Rampa - 7 Years Ago
If you use a Persona with a walk command, it will follow terrain. Applying a motion any other way will not.

The reason is that the terrain tracking relies on the character's pivot, which is right beneath them at ground level. When you use a Persona move command it is moving the pivot and playing an in-place animation at the same time. That feature works the same way characters in games move.

When you are applying motions else-wise, you will actually need to key the transforms to keep them above ground. So add a key on Z wherever you need the height to change.

EDIT:
Just discovered something else important!
If "Using Bounding Mesh" is checked for your terrain, it does not register as terrain, and you will not get foot contact if it's enabled. So select your terrain in the Scene Manager and un-check the box in the Modify panel.
https://forum.reallusion.com/uploads/images/8e667ebb-b463-4998-92b1-8398.jpg
This is a bug, and can be reported in the Feedback Tracker.

By colour - 7 Years Ago
Rampa (10/14/2017)
If you use a Persona with a walk command, it will follow terrain. Applying a motion any other way will not.

The reason is that the terrain tracking relies on the character's pivot, which is right beneath them at ground level. When you use a Persona move command it is moving the pivot and playing an in-place animation at the same time. That feature works the same way characters in games move.

When you are applying motions else-wise, you will actually need to key the transforms to keep them above ground. So add a key on Z wherever you need the height to change.


Rampa has the correct answer. Smile

Just done another Screenshot Test & was going to post that & suggest you PM Rampa, anyway

TBH, although I'm aware that Character's pivot point is at ground level, I wasn't aware of Rampa's explanation re; Key-framing non-Persona Motions. So, Thanks Rampa. Smile


By billwright - 7 Years Ago
My apologies - I am still new to this and to the terminologies.
I thought the example from my provided screenshots were done NOT using the persona.
Do I need to remove the persona from the character before applying the 'other' motions?
Isn't 'Clear Animations' the same as eliminating the persona?

I guess from all of your great answers I can proceed as I did in the screenshots but need to set a keyframe at the start with the height above the terrain that wish the character to have?

By billwright - 7 Years Ago
OK - next wrinkle - my modify screen for terrain https://forum.reallusion.com/uploads/images/e0949463-b9b5-4fd4-b367-1fed.jpgdoes not show that mesh checkbox.

By Rampa - 7 Years Ago
billwright (10/14/2017)
My apologies - I am still new to this and to the terminologies.
I thought the example from my provided screenshots were done NOT using the persona.
Do I need to remove the persona from the character before applying the 'other' motions?
Isn't 'Clear Animations' the same as eliminating the persona?

I guess from all of your great answers I can proceed as I did in the screenshots but need to set a keyframe at the start with the height above the terrain that wish the character to have?



Hi Bill. I noticed you were not using a Persona, and so gave the keying info. Smile

A Persona associates certain animations with the right-click menu of a character. They are almost exclusively used for "Perform" motions these days, rather than move commands. They are actually a hold-over from an earlier incarnation of iClone, but they still work.

The ones in the latest iClone do not contain move commands, but only perform commands, which are similar to adding a motion from the Content Manager.
https://forum.reallusion.com/uploads/images/fc743577-96e9-42a9-8052-9ba6.jpg

By Rampa - 7 Years Ago
billwright (10/14/2017)
OK - next wrinkle - my modify screen for terrain https://forum.reallusion.com/uploads/images/e0949463-b9b5-4fd4-b367-1fed.jpgdoes not show that mesh checkbox.



Sorry. I was not clear enough in my description. Made assumptions. Blush
I meant the "Floor" you added to your scene and converted to terrain.
https://forum.reallusion.com/uploads/images/532c81ca-596a-4e3e-bc75-16e7.jpg
By billwright - 7 Years Ago
Initially I tried adding the persona (Mason) to my character but the perform actions (walk and think, walk bump into object) are the only two walking actions.  The Walk think option sends the character out of the screen frame and the walk bump into object action is just strange.


By Rampa - 7 Years Ago
Even though it makes the character walk, that is actually a "Perform" command. There used to be Personas that included both a "Perform" and "Move" in the r-click menu. The current ones only have "Perform".

The "move" worked in a much different way. If you imagine the character in a box, and move that box while the character animates in place inside it, that is what the "Move" command did. That is usually how a character works in games.

If you would like to try one that has "Move" commands, you may download this custom one that I made.
https://drive.google.com/open?id=0B3nsNVGroEz6cFp2ODQxX1hnUkE

It is comprised of two parts. The Persona file, which you can store in any folder you like, and a folder full of iMotions. Put that folder full of iMotions  into your Template motion folder. C:\Users\Public\Documents\Reallusion\Template\iClone 7 Template\iClone Template\Motion

When you load the Persona, it will have a "Move" in the r-click menu. Selecting "Move" will present you with several options in a fly-out sub-menu. There are also a couple "Perform" motions included.
By billwright - 7 Years Ago
Thank you - I appreciate the aml and the motions.
Looks like if I am going to accomplish what I need to do I will need to figure out how to write / edit persona's and motions!


By billwright - 7 Years Ago
That clarifies it.  I can now have my character walk on the porch..
All of your help is really appreciated.

By Rampa - 7 Years Ago
Glad it worked! Smile
You can take it a step further by creating a path that you want the character to follow. to do so right click and select a move command for your character, and then click on any path in your scene. The character will walk to the near end of the path and then along it. Note that you do not attach the character to the path to do this. So you can walk easily from one path to another.
By Cary B - 7 Years Ago
Sorry I confused things by misunderstanding your issue. I had a very similar issue working with custom personas I created in 3dx 7, but it's a different problem, though it results in the same kind of glitch. I'm glad Rampa was able to set things straight. 
By billwright - 7 Years Ago
Thanks again.
Now I'll be posting another question dealing with vehicle motions Smile
By jimbobsquarepants - 6 Years Ago
Hi everyone, hope I'm at the right forum for this!! Ive just read some of the posts here and I wonder if I could explainmy issue? In iclone 7 I have a road set, created in sketchup and a bike model also created in sketchup. Both props added to my scene. I want the bike to move over the curves in the road so I selected follow terrain from the edit menu but the bike just moves through it. So I created a path and then chose snap to terrain. But it snapped to a straight line above the curves below. Is this rectified by using the self mesh option or am I stuck with the bounding box rectangle surrounding my road prop? Any help would be great here as I can't move on to my next scene. I could key frame the bike but that's a ton of work and I' know there must be a way to get it to snap to the set prop. Thanks. Jim
By 4u2ges - 6 Years Ago
jimbobsquarepants (9/3/2018)
Hi everyone, hope I'm at the right forum for this!! Ive just read some of the posts here and I wonder if I could explainmy issue? In iclone 7 I have a road set, created in sketchup and a bike model also created in sketchup. Both props added to my scene. I want the bike to move over the curves in the road so I selected follow terrain from the edit menu but the bike just moves through it. So I created a path and then chose snap to terrain. But it snapped to a straight line above the curves below. Is this rectified by using the self mesh option or am I stuck with the bounding box rectangle surrounding my road prop? Any help would be great here as I can't move on to my next scene. I could key frame the bike but that's a ton of work and I' know there must be a way to get it to snap to the set prop. Thanks. Jim

It is a bug yet to be addressed by RL https://www.reallusion.com/FeedBackTracker/Issue/Follow-Terrain-and-Projected-Path-Inconsistensy
Here is one way to handle it at the moment: