[1.0.12.9] Airstrip and Missile Silo banners different position when built in 3D and 2D views

bolbas

Warlord
Joined
Jan 10, 2017
Messages
107
Airstrip's and Missile Silo's banners appear at different positions when build them in 3D and 2D views. - EXISTS in 1.0.12.9.
To reproduse:
1. Build Airstrip or Missile Silo in 3D view.
2. Build Airstrip or Missile Silo to the right or to the left of the first one in 2D view.
3. Check their banners positions in 3D and 2D views.

Airstrip's banner built in 2D view is in the middle on screenshots below and Missile Silo's banner built in 2D view is to the left.
Spoiler :



 
Last edited:

bolbas

Warlord
Joined
Jan 10, 2017
Messages
107
1.0.6.9 - the bug still exists (see first post).

@Ekmek, just build one Airstrip from 3D View then build one more from Strategy View and compare their banners positions.
 

robal1991

Warlord
Joined
May 2, 2011
Messages
171
Location
Poland
I can confirm this bug. I made some research on it and found the problem.
In CityBannerManager.lua somehow the UpdatePosition() method is not called for missile silo and airstrip banners when world view changes (3d or strategic view).

To fix this you need to add this code to the OnRefreshBannerPositions() method at the end of the "for i, player in ipairs(players)" loop:
Code:
local playerMiniBannerInstances = MiniBannerInstances[ playerID ];
if (playerMiniBannerInstances ~= nil) then
    for id, banner in pairs(playerMiniBannerInstances) do
        if (banner ~= nil and (banner.m_Type == BANNERTYPE_MISSILE_SILO or banner.m_Type == BANNERTYPE_AERODROME)) then
            banner:UpdatePosition();
        end
    end
end
 
Top Bottom