Documentation (unit details) resizing IMPLEMENTED

Suggestions about the gameplay, the controls, buttons and so on.
Post Reply
User avatar
Endru1241
Posts: 2717
Joined: Fri Sep 11, 2015 8:43 am
Location: Poland

Documentation (unit details) resizing IMPLEMENTED

Post by Endru1241 »

In unit/building details page the whole frame resizes to be too wide when unit has animation (actually any many frame graphics).
Shouldn't different settings in unit visuals definition be read and applied?
To make it simpler just read number of columns in "type":"DEFAULT" and image definition to take only first one for documentation.
To see castle stats we don't really have to view all produced units animation frames (neither occupied/non occupied images is needed, but new image split way deals with that already).
Age of Strategy design leader
Stratego (dev)
Site Admin
Posts: 15741
Joined: Fri Apr 25, 2014 9:28 pm

Re: Documentation (unit details) resizing

Post by Stratego (dev) »

lol. sure it is not good, it is not easy to solve as that is a html template (u see it under templates), not within the app, but a in-game-browser shows that html

in template there should be the image placed cropped to good size - bit still should work for all image sizes, double and mega castle too :)

in tp_propsheet here is the image:

<tmpl_if up_img>
<img src="<tmpl_var up_img>" />
<tmpl_else>
<img src="<tmpl_var up_img_double>" />
</tmpl_if>

maybe some sizing would help, but i have never hassled with it.
User avatar
Endru1241
Posts: 2717
Joined: Fri Sep 11, 2015 8:43 am
Location: Poland

Re: Documentation (unit details) resizing

Post by Endru1241 »

I doubt anything can be achieved by html here.
The question is what and when is supplied to main document (do I understand it right, that there is one huge html file generated, then by javascript document.getElementById(a) a correct branch is selected?). I mean - if in up_unit_type_img variable already processed image would be stored, then there is no problem.
Age of Strategy design leader
Stratego (dev)
Site Admin
Posts: 15741
Joined: Fri Apr 25, 2014 9:28 pm

Re: Documentation (unit details) resizing

Post by Stratego (dev) »

no we can only reference files in asset folder.

the small statsheed is generated by templating (filling up with data)
and the big help uses this little generatedthings to copy into a whole big html.

we can try making in html size constraints for the image, orr putting it into a div and restrict size - you can try if u have a little affinity, with modding you can instantly test it.
User avatar
Endru1241
Posts: 2717
Joined: Fri Sep 11, 2015 8:43 am
Location: Poland

Re: Documentation (unit details) resizing

Post by Endru1241 »

I remembered right that nothing can be achieved by html alone. Forgot, about css.
So, you were right. It could be done in html file.
I did it (will be added in the next pack).
Age of Strategy design leader
Stratego (dev)
Site Admin
Posts: 15741
Joined: Fri Apr 25, 2014 9:28 pm

Re: Documentation (unit details) resizing

Post by Stratego (dev) »

You are awesome! please send me the file itself as i need to put it into toher variants - thanks!
User avatar
Endru1241
Posts: 2717
Joined: Fri Sep 11, 2015 8:43 am
Location: Poland

Re: Documentation (unit details) resizing

Post by Endru1241 »

Sent on e-mail. Forum doesn't allow html attachments.
Age of Strategy design leader
Post Reply

Return to “Gameplay & UI”