View Issue Details

IDProjectCategoryLast Update
0019321AI War 2Graphical BugJan 17, 2018 12:47 pm
ReporterBadgerBadger Assigned ToBadgerBadger  
Status closedResolutionfixed 
Product Version0.612 
Fixed in Version0.702 Activating Mk1 Grinding Machine 
Summary0019321: holding down Shift to see move command fails with wormhole traversal
DescriptionThe code to generate the lines is in here:

        public void DrawSquadOrders()
         {
               List<EntityOrder> orders = this.RelatedEntity.EntitySpecificOrders.QueuedOrders;
              foreach(orders)
                newPoint = order.RelatedPoint.ToVisualMainGameCoordinates();

           //Draw line involving newPoint
        }
However, when you create a wormhole order you use
        public static EntityOrder Create_Wormhole( int RelatedPlanetIndex, bool CameFromPlayer, bool RefuseToWait )

              EntityOrder result = new EntityOrder( EntityOrderType.Wormhole, ArcenPoint.ZeroZeroPoint, -1, RelatedPlanetIndex, CameFromPlayer, RefuseToWait );
          
This will mean that our "RelatedPoint" is AcrenPoint.ZeroZeroPoint, so when the user holds Shift to see where the ships are going, it will give us a blue line off into the distance.

A couple obvious choices. One is to have the Core code retain awareness of the ArcenPoint of the wormhole's actual location so we can look it up.
Another would be to have the SquadVisualizer code figure out where the Wormhole is. I am open to suggestions
TagsNo tags attached.

Activities

BadgerBadger

Dec 23, 2017 12:28 pm

manager   ~0046646

I can't take a picture while holding down Shift on my computer, but here's a save game you can use to recreate it. Just hold down "Shift" and send the ships through the wormhole.

BadgerBadger

Jan 16, 2018 11:36 am

manager   ~0046686

Note this save game is pre-.700 so it won't work anymore.

Chris_McElligottPark

Jan 16, 2018 11:41 am

administrator   ~0046687

From Keith, just for posterity:

that's because the RelatedPoint of the order is ZeroZero, which is literally where those lines are pointing.

So for that specific EntityOrderType, it should not use RelatedPoint at all but instead RelatedPlanetIndex or whatever it is, and derive a point from that by:
- get the planet object for that index
- on the current planet's object, call GetWormholeTo(relatedPlanet)
- use that wormhole's WorldLocation

Issue History

Date Modified Username Field Change
Dec 23, 2017 11:09 am BadgerBadger New Issue
Dec 23, 2017 11:09 am BadgerBadger Status new => assigned
Dec 23, 2017 11:09 am BadgerBadger Assigned To => keith.lamothe
Dec 23, 2017 12:28 pm BadgerBadger File Added: recreate~#SI#476927155#177#recreate#Vanilla#Normal.save
Dec 23, 2017 12:28 pm BadgerBadger Note Added: 0046646
Jan 16, 2018 11:36 am BadgerBadger Note Added: 0046686
Jan 16, 2018 11:41 am Chris_McElligottPark Note Added: 0046687
Jan 16, 2018 11:47 am BadgerBadger Assigned To keith.lamothe => BadgerBadger
Jan 17, 2018 12:47 pm BadgerBadger Status assigned => closed
Jan 17, 2018 12:47 pm BadgerBadger Resolution open => fixed
Jan 17, 2018 12:47 pm BadgerBadger Fixed in Version => 0.702 Activating Mk1 Grinding Machine