I have a viking fly out to a point and land, then turn into a bunker, through triggers. I take control of the viking, rally it to the point it's meant to transform, and queue it up to land. This fires another trigger on Unit - Any Unit uses Viking - Assault Mode at Generic6 - Complete stage (ignoring shared abilities), which does some stuff. It all works, but the bunker it changes into is massively off-center, towards the bottom-right.
The action I'm using to spawn the bunker is "Create 1 Bunker for player (Owner of (Triggering unit)) at (Position of (Triggering unit)) using default facing (No Options)". The triggering unit is the viking.
I can also use "at (Center of regions[i])", i being the integer I'm using to iterate over the list of regions in regions, one of which I sent the viking to land dead center of, the same point returned by Center of regions[i]. This yields the same result.
Being an idiot at the data editor, I've edited the size of the bunker to 2*2, by finding it in units, clicking the "footprint 3*3" thing in the treeview, and changing it to 2*2. I don't know if this is affecting anything.
I'm not entirely certain what you're on about, but the regions are 8 by 8. With the bunker being 2 by 2, there should be 3 hexes of space on all sides of the bunker, to the edge of the region.
EDIT: Wow, literally seconds after, I worked it out. I create the bunker before I remove the viking, for some clever reason I liked at the time, and thus still do now. The bunker can't be placed on top of it, though.
So I need to ignore placement. Any particularly easy way to do that?
I have a viking fly out to a point and land, then turn into a bunker, through triggers. I take control of the viking, rally it to the point it's meant to transform, and queue it up to land. This fires another trigger on Unit - Any Unit uses Viking - Assault Mode at Generic6 - Complete stage (ignoring shared abilities), which does some stuff. It all works, but the bunker it changes into is massively off-center, towards the bottom-right.
The action I'm using to spawn the bunker is "Create 1 Bunker for player (Owner of (Triggering unit)) at (Position of (Triggering unit)) using default facing (No Options)". The triggering unit is the viking.
I can also use "at (Center of regions[i])", i being the integer I'm using to iterate over the list of regions in regions, one of which I sent the viking to land dead center of, the same point returned by Center of regions[i]. This yields the same result.
Being an idiot at the data editor, I've edited the size of the bunker to 2*2, by finding it in units, clicking the "footprint 3*3" thing in the treeview, and changing it to 2*2. I don't know if this is affecting anything.
Thank you for your time.
the problem might be the the bunker snaps to the raster and the viking is not
@b0ne123:
I'm not entirely certain what you're on about, but the regions are 8 by 8. With the bunker being 2 by 2, there should be 3 hexes of space on all sides of the bunker, to the edge of the region.
Bump. (Is that allowed?)
EDIT: Wow, literally seconds after, I worked it out. I create the bunker before I remove the viking, for some clever reason I liked at the time, and thus still do now. The bunker can't be placed on top of it, though.
So I need to ignore placement. Any particularly easy way to do that?
@Asday: Go
Ignore Placement should be one of the options under the (No Options) in the create bunker trigger.
Wow, that was easy.
I'll report back on the next round of testing. :3