So basically i'm working on a top down, endless survival game were enemies infinetly spawn, the thing is in the man script their being instanced and their x and y position are being set once that happen they follow the player. I want their to be 3 different enemies so how would i made 3 diffrent sprites 2d how would i set a sprite to be the one? (2d, using gdscript)
thanks
#how to completely swap sprites godot
6 messages · Page 1 of 1 (latest)
if u like u can instead make 3 different enemy scenes
select a random one from the enemy scenes
then instance it.
this approach can allow you to have multiple enemies with modifiable elements instead of 3 different image with the same elements
but if u really want it that way
i guess u can do it this waytexture = preload("res://Assets/characters_packed.png")
change the resource to what u have ofcourse
yeah i think i'll go with your approach, i'll make 3 diffrent enemy scenes and instead when making an enemy i'll randomly pick one of the 3, thanks