You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to create a 2d game where the sprites have a color texture and a normal map texture for lighting. The shader_material.rs example can be relatively easily converted to 2d, however the custom_material.wgsl is erroring because the uv variable isn't provided for Material2d but is for Material as far as I can tell. What is the easiest way to fix this, and are there any good learning resources for creating custom Material2ds in general?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to create a 2d game where the sprites have a color texture and a normal map texture for lighting. The
shader_material.rs
example can be relatively easily converted to 2d, however thecustom_material.wgsl
is erroring because theuv
variable isn't provided forMaterial2d
but is forMaterial
as far as I can tell. What is the easiest way to fix this, and are there any good learning resources for creating customMaterial2d
s in general?Beta Was this translation helpful? Give feedback.
All reactions