How to animate material property with AnimationPlayer?

Godot Version

Godot v4.2.1.stable - Ubuntu 22.04.3 LTS 22.04 - Tty - Vulkan (Forward+) - dedicated NVIDIA GeForce GTX 970 (nvidia) - Intel(R) Core™ i7-4790K CPU @ 4.00GHz (2 Threads)

Question

What is the best way to animate a material property, for example albedo, using AnimationPlayer?

Just make sure that the material is created in advance, and the process for adding the values to AnimationPlayer is pretty much the same as for any kind of property. However, the UI is a bit lacking so you need to do in a specific order to get the “key icons” for adding the property to AnimationPlayer to show up. From memory, the process is something like this:

  1. Create the material
  2. Select the AnimationPlayer node and make sure the AnimationPlayer window is displayed
  3. Select the node with the material and then directly select the material from there. You should now see the key icons for the material.
1 Like

Fine. This was what I was looking for.
Thank you!