Lightmap and object animations

  • #1, by tom-barnetWednesday, 01. December 2021, 16:28 2 years ago
    Is it possible to somehow make the lightmap affect the animations within a scene? 

    I have an object that starts moving under some conditions. The lightmap affects its static image (set in effects), however, when the image is replaced by the animation, the light map stops having the effect. 

    Newbie

    37 Posts


  • #2, by afrlmeWednesday, 01. December 2021, 17:21 2 years ago
    I'm not sure how the lightmap actually works in regards to objects. Have you tried having the animation playing from the start?  When you start an animation via the play animation part it doesn't inherit all the properties belonging to the scene object, only animations linked as the default animation do - or at least that's how it used to work.

    Are you using the animation to animate the movement across the scene or are you using an action part or script to move the scene object itself?

    Imperator

    7278 Posts

  • #3, by tom-barnetWednesday, 01. December 2021, 21:16 2 years ago
    The former; it is quite a complicated movement (moving plant with tentacles) so it cannot be scripted like for example clouds. The animation cannot play from the start, as the movement is triggered only by interaction with the player.

    Edit: I just tried to set the animation as default in object properties, but it doesn't seem to be affected by the lightmap anyway.

    Newbie

    37 Posts

  • #4, by afrlmeThursday, 02. December 2021, 13:44 2 years ago
    The plant itself stays in the same position & the tentacles move across the scene? Either way I don't think the lightmap would be viable as it's based on the position of the object itself as far as I'm aware, & not where the image is touching the screen. It would probably be better for you to manually add the tint yourself to the frames via photoshop or something. Only other solution I can think of would be masking - it might work, basically you would use the lightmap as a mask & assign it to the object, it should tint anything belonging to the object as long as the image is semi-transparent, or it might tint the entire thing as the mask. It's been quite a while since I messed with masks so I don't recall exactly how they work, but here is a ved file with resources (that I made a couple of years back) showcasing a bunch of different masking techniques: https://www.dropbox.com/s/zi7sprb0y9cszjz/mask_test.zip?dl=0

    Imperator

    7278 Posts

  • #5, by tom-barnetMonday, 06. December 2021, 18:51 2 years ago
    Thank you, all you're saying is correct. I will try to play with and learn about the masking and see where it gets me.

    Newbie

    37 Posts

  • #6, by SimonSMonday, 06. December 2021, 19:25 2 years ago
    Lightmaps also work on object animations. I checked it again, that works. The used color is set by the object position.

    Thread Captain

    1580 Posts