how to get origin point of some animation at runtime?

1MrPaul1

  • *
  • Posts: 1285
I know that we do not have blocks for getting x and y origin points but may be we can use some code for this?


LIBERADO

  • *
  • Posts: 2719
Look here.
"An Error Has Occurred!
The topic or board you are looking for appears to be either missing or off limits to you."

 :-[
I'm spanish, excuse me for my bad English.
I'm not a private teacher. Please, post your questions in the public forum.

captaincomic

  • *
  • Posts: 6108
It's from the customers sections.
The relevant info is:
actor.originX
actor.originY

...
(if not using in an Actor behavior, replace "actor" with the internal name of your actor attribute)

...
actor.originX and actor.originY will give you offsets from the centre of the sprite, but when you set origins from Appearance tab you actually set offsets from top left corner, so anyone who would use them should keep this in mind.
...

LIBERADO

  • *
  • Posts: 2719
I'm spanish, excuse me for my bad English.
I'm not a private teacher. Please, post your questions in the public forum.

1MrPaul1

  • *
  • Posts: 1285

searched on the forum for this post but did not found...

Thank you Captain!