#image_xscale question

1 messages · Page 1 of 1 (latest)

ionic lily
#

hi there! i am a bit of a newbie to gamemaker and programming in general. i have a cutscene system going right now and am trying to make a simple function that flips an object's sprite. i must be doing something wrong, because this doesn't seem to have any effect.


        with(obj_id){
            
            image_xscale = -image_xscale
        }

    cutscene_end_action()
    
    }``` 

to be clear, im giving it the object's id as the argument there, in this case the name of the object in game maker's asset view. when i call this, it calls my cutscene_end_action function fine, but doesn't have any effect on the object itself.
regal furnace
#

sounds like your with-statement might not be doing anything due to a bad instance ref

frank crypt
#

or, there's custom draw code in draw event

regal furnace
#

which might not even make use of image_xscale, yeah

frank crypt
#

for example draw_sprite(sprite_index, image_index, x, y) doesn't use it

ionic lily
#

ohh that's definetly it. i didn't realize they don't make use of those values even though they're not defined within it. maybe i should use draw_sprite_ext instead, then?

#

or maybe just draw_self since it appears to use all built in variables?