Page 1 of 1

[Rseding91] [1.1.39] create_entity ignores direction

Posted: Thu Sep 09, 2021 2:24 pm
by eradicator
According to the doc create_entity accepts direction, but when trying to spawn a character it's always spawned facing north. Did not test with other entity types.

Code: Select all

/c game.player.surface.create_entity{name='character', direction=defines.direction.south, position={0,0}}

Re: [1.1.39] create_entity ignores direction

Posted: Thu Sep 09, 2021 3:36 pm
by Rseding91
Thanks for the report. Character entities use "orientation" not direction.

Re: [1.1.39] create_entity ignores direction

Posted: Thu Sep 09, 2021 5:12 pm
by Rseding91
Actually I was wrong. It does use direction. I'll look into it more.

Re: [1.1.39] create_entity ignores direction

Posted: Thu Sep 09, 2021 6:33 pm
by eradicator
Rseding91 wrote: Thu Sep 09, 2021 3:36 pm Thanks for the report. Character entities use "orientation" not direction.
That would've broken all my other code in quite obvious ways. :mrgreen:

Thanks for fixing.