system
1
|
|
|
 |
Attention |
Topic was automatically imported from the old Question2Answer platform. |
 |
Asked By |
potatobanana |
i have two sprite male and female, with different region set, but i dont know how to set_region_rect ,
i do like this but wont work
$playerBase/skin.set_region_rect(32, 800, 32 , 64)
sorry for my broken english
system
2
|
|
|
 |
Reply From: |
kidscancode |
region_rect
takes a Rect2 object, not a list of four integers.
$playerBase/skin.region_rect = Rect2(32, 800, 32, 64)
https://docs.godotengine.org/en/latest/classes/class_sprite.html#class-sprite-property-region-rect
thank you very much, you help me allot more than all doc, i did read doc but cant understand it. thank you.
potatobanana | 2019-02-19 13:09
1 Like