Lou Montana/Sandbox – User

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "{{SideTOC}}" to "{{TOC|side}}")
(Doc/Template template?)
Line 1: Line 1:
<!-- {{TOC|side}} -->[[Category: Sandbox]]
[[Category: Sandbox]]
↓ anyone feels like filling the table below…? ↓
<includeonly>{{{descr|}}}


= Arma 3: Vehicles Data =
== Usage ==
''Arma 3: Vehicles Data: Fuel and Speed?''
{{<nowiki/>{{{name|{{PAGENAME}}}}}<!--
-->{{#if:{{{arg1|}}} | {{!}}'''''{{{arg1}}}'''''}}<!--
-->{{#if:{{{arg2|}}} | {{!}}'''''{{{arg2}}}'''''}}<!--
-->{{#if:{{{arg3|}}} | {{!}}'''''{{{arg3}}}'''''}}<!--
-->{{#if:{{{arg4|}}} | {{!}}'''''{{{arg4}}}'''''}}<!--
-->{{#if:{{{arg5|}}} | {{!}}'''''{{{arg5}}}'''''}}<!--
--><nowiki>}}</nowiki>
{{#if:{{{arg1|}}}|
* {{{arg1}}}{{#if:{{{descr1|}}}|<nowiki/>: {{{descr1|}}}}}
}}<!--
-->{{#if:{{{arg2|}}}|
* {{{arg2}}}{{#if:{{{descr2|}}}|<nowiki/>: {{{descr2|}}}}}
}}<!--
-->{{#if:{{{arg3|}}}|
* {{{arg3}}}{{#if:{{{descr3|}}}|<nowiki/>: {{{descr3|}}}}}
}}<!--
-->{{#if:{{{arg4|}}}|
* {{{arg4}}}{{#if:{{{descr4|}}}|<nowiki/>: {{{descr4|}}}}}
}}<!--
-->{{#if:{{{arg5|}}}|
* {{{arg5}}}{{#if:{{{descr5|}}}|<nowiki/>: {{{descr5|}}}}}
}}


{| class="wikitable sortable"
{{#if:{{{example1|}}}{{{example2|}}}{{{example3|}}}{{{example4|}}}{{{example5|}}}{{{result1|}}}{{{result2|}}}{{{result3|}}}{{{result4|}}}{{{result5|}}}
!rowspan="2" | Class !! rowspan="2" | Name !! colspan="4" | Full tank consumption time !! colspan="3" | Speed
|
|-
{{{!}}
! Idle !! slow speed !! medium speed !! max speed !! slow speed !! medium speed !! max speed
{{!}}+ Examples
|-
{{!}}- style{{=}}"background-color: #EEE"
| B_Truck_01_mover_F || HEMTT || 05:18:00 || 03:15:00 || 03:38:00 || 03:18:00 || 026,83 km/h || 070,94 km/h || 082,85 km/h
! Code
|-
! Result
| B_MRAP_01_F || Hunter (unarmed) || 04:33:00 || 02:47:00 || 01:56:00 || 01:44:00 || 037,13 km/h || 099,81 km/h || 116,45 km/h
{{!}}-
|-
{{#if: {{{example1|}}}
| B_LSV_01_unarmed_F || Prowler (unarmed) || 04:09:00 || 01:38:00 || 01:50:00 || 01:38:00 || 053,96 km/h || 147,06 km/h || 172,47 km/h
|
|-
{{!}}-
| B_Quadbike_01_F || Quad || 01:54:00 || 01:09:00 || 01:12:00 || 01:06:00 || 027,14 km/h || 070,77 km/h || 082,20 km/h
{{!}} {{{example1|}}}
|-
{{!}} {{{result1|}}}
| B_APC_Tracked_01_AA_F || IFV-6a Cheetah || 03:11:00 || 02:07:00 || 02:14:00 || 01:56:00 || 023,31 km/h || 046,31 km/h || 061,07 km/h
}}
|-
{{#if: {{{example2|}}}
| B_APC_Wheeled_01_cannon_F || AMV-7 Marshall || 04:55:00 || 02:58:00 || 02:58:00 || 02:34:00 || 036,20 km/h || 060,41 km/h || 113,00 km/h
|
|-
{{!}}-
| B_APC_Tracked_01_CRV_F || CRV-6e Bobcat || 03:11:00 || 02:05:00 || 02:13:00 || 01:55:00 || 023,31 km/h || 046,31 km/h || 061,07 km/h
{{!}} {{{example2|}}}
|}
{{!}} {{{result2|}}}
}}
{{#if: {{{example3|}}}
|
{{!}}-
{{!}} {{{example3|}}}
{{!}} {{{result3|}}}
}}
{{#if: {{{example4|}}}
|
{{!}}-
{{!}} {{{example4|}}}
{{!}} {{{result4|}}}
}}
{{#if: {{{example5|}}}
|
{{!}}-
{{!}} {{{example5|}}}
{{!}} {{{result5|}}}
}}
{{!}}}
}}


Code used:
{{#ifeq:{{uc:{{FULLPAGENAME}}}} | USER:LOU MONTANA/SANDBOX
<spoiler><pre>veh = vehicle player;
| [<nowiki/>[Category: Templates{{!}}{{<nowiki/>uc:{{<nowiki/>PAGENAME}}}}]]
wantedDelta = 3;
| [[Category: Templates|{{uc:{{PAGENAME}}}}]]
}}
</includeonly><noinclude>


previousPos = [0,0,0];
{{User:Lou_Montana/Sandbox
currentPos = [0,0,0];
|descr = this is my description
previousFuel = 0;
| arg1 = message
currentFuel = 0;
| descr1 = the message to display
t = 0;
| example5 = <nowiki>{{Template|sic}}</nowiki>
 
| result5 = {{Template|sic}}
onEachFrame {
}}
isNil {
</noinclude>
vehSpeed = speed veh;
 
if (t <= time) then {
previousPos = currentPos;
currentPos = getPosATL veh;
distanceDelta = currentPos distance previousPos;
previousFuel = currentFuel;
currentFuel = fuel veh;
 
fuelLossPerMinute = (previousFuel - currentFuel) * (60 / (wantedDelta + (time - t)));
 
remainingTime = if (fuelLossPerMinute > 0) then {
[(currentFuel / fuelLossPerMinute) * 60, "HH:MM:SS"] call BIS_fnc_secondsToString;
} else { -1 };
 
timeToEmpty = if (fuelLossPerMinute > 0) then {
[(1 / fuelLossPerMinute) * 60, "HH:MM:SS"] call BIS_fnc_secondsToString;
} else { -1 };
 
t = time + wantedDelta;
};
 
hintSilent format [
"Speed: %1\nFuel loss: %2\n\nRemaining time: %3\nTime to empty: %4",
vehSpeed,
fuelLossPerMinute,
remainingTime,
timeToEmpty];
 
copyToClipboard format ["[%1, %2, %3]", typeOf veh, timeToEmpty, vehSpeed];
};
};
</pre></spoiler>

Revision as of 01:40, 5 January 2021

this is my description

Usage

{{Lou Montana/Sandbox|message}}

  • message: the message to display
Examples
Code Result
{{Template|sic}} {{sic}}

[[Category: Templates|{{uc:{{PAGENAME}}}}]]