Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Create an account below if you want to be able to make edits.

Template:Scrollable Math: Difference between revisions

Template page
No edit summary
Fix long equation formatting
 
(2 intermediate revisions by one other user not shown)
Line 2: Line 2:


<div class="scrollable-math">
<div class="scrollable-math">
   <math>
   {{{1}}}
    {{{1}}}
  </math>
</div></includeonly>
</div></includeonly>


Line 15: Line 13:
<math>E = mc^2</math>
<math>E = mc^2</math>
}}
}}


{{Scrollable Math|
{{Scrollable Math|
<math>
<math>\text{attackerTroopLoss(tileOwner)} =  
\text{attackerTroopLoss(tileOwner)} =
\begin {cases}
\begin{cases}
0.8 * \text{terrainDef} * \text{defensePost} * \text{botDebuff} * \text{largeAttackerBuff} * \text{largeDefenderDebuff} * \text{traitorDebuff} * \text{clampedTroopRatio} & \text{if player or nation or bot} &\\
0.8 \cdot \text{terrainDef} \cdot \text{defensePost} \cdot \text{botDebuff} \cdot \text{largeAttackerBuff} \cdot \text{largeDefenderDebuff} \cdot \text{traitorDebuff} \cdot \text{clampedTroopRatio} & \text{if player or nation or bot} \\
\frac{\text{terrainDef} * \text{falloutDef}}{\text{attackerTypeBuff}} & \text{if wilderness}
\frac{\text{terrainDef} \cdot \text{falloutDef}}{\text{attackerTypeBuff}} & \text{if wilderness}
\end{cases}</math>}}
\end{cases}
</math>
}}
</noinclude>

Latest revision as of 20:59, 17 November 2025


This template wraps math formulas in a horizontally scrollable container for mobile devices.

Usage:

E=mc2



attackerTroopLoss(tileOwner)={0.8*terrainDef*defensePost*botDebuff*largeAttackerBuff*largeDefenderDebuff*traitorDebuff*clampedTroopRatioif player or nation or botterrainDef*falloutDefattackerTypeBuffif wilderness