Jump to content

Animated models shadows


Frenchgui
 Share

Recommended Posts

I have something similar on the converted DA game.

 

Idle animation doesn't animate shadow, but if character is moving it animates.

Does pointlight have some sort of movement tracking so shadows become static if entity isn't moving?

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

Yes, you're right shadmar!!! As my scene is quite empty (it was just for learning animations), so nothing uses physics. As soon as I've put some boxes (in unstable position) shadows are working fine. As soon as everything is on floor and idle, shadows stop updating. I will try using a physic camera to force shadow update. Thanks!!!

 

edit: Ok I've tried it, but character physic doesn't update physics save if they collide. So I have to find a trick, or maybe Josh can add an option to enable/disable update shadows continuesly.

fn9smb.png
Link to comment
Share on other sites

It should work with animation. It is possible it might not under the right circumstances. I never encountered this with the example game level.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Hello Josh. To see the shadow trouble, just put a floor, a point light and the crawler model with this script:

 

Script.Speed=1.0--float

Script.Sequence=2--int

entpos = Vec3(0,0,0)

Script.angle=50.0--float

 

function Script:Draw()

-- move entity a bit for shadow updating

self.angle = self.angle + 1.0

if self.angle >= 360 then

self.angle=0

end

entpos = self.entity:GetPosition()

entpos.x = entpos.x + Math:Sin(self.angle)/100

entpos.z = entpos.z + Math:Cos(self.angle)/100 + 0.001

self.entity:SetPosition(entpos.x , entpos.y , entpos.z)

 

local t = Time:GetCurrent()

self.entity:SetAnimationFrame(t/100.0*self.Speed,1,self.Sequence)

end

 

... and a camera. As you can see, model is animating and moving, but not shadows.

fn9smb.png
Link to comment
Share on other sites

This is a confirmed bug. I will start a new round of fixes next week. You don't need to do anything else, thank you.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

×
×
  • Create New...