[WiP] <RetVar> = get maximum, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>

This forum serves as MSCI Reference at EGOSOFT. It's Read-Only for non MSCI Group members.

Moderators: Scripting / Modding Moderators, MSCI Moderators

Post Reply
mark_a_condren
Posts: 1385
Joined: Wed, 3. Aug 05, 05:05
x3tc

[WiP] <RetVar> = get maximum, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>

Post by mark_a_condren » Fri, 10. Sep 10, 13:50

<RetVar> = get maximum, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>


<RetVar> = Returns the highest of all given integer values.
<Var/Number> = Upto 5 integer values can be entered for evaluation. These can be entered as a variable containing a numeric (integer) value.

Returns the highest of all given integer values.
All <Var/Number> entries must be 'integer' ( DATATYP_INT ) entries. You cannot enter strings into this command.

You can enter this value as a simple 'integer', for example 506, as in the example, but you can also enter a variable like $highest.value.1, $highest.value.2, and so on, which could be results from calculations of other scripts in order to determine the highest result.


Examples:

$highest.value = get maximum, 16, 203, 87, 506, 111

In the above example, $highest.value would equal 506.

--------------------------------------------

$highest.value = get maximum, 16, $integer.1, 87, $integer.2, 111

In the above example, $highest.value would equal the highest value of all the <Var/Number> entries. You can mix directly entered integers and variables containing integers.


Command Location:
  • »» General Commands
    <RetVar> = get maximum, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>
Last edited by mark_a_condren on Sat, 2. Oct 10, 07:48, edited 1 time in total.

Alex Vanderbilt
Winner X3 Sektorquest
Posts: 2119
Joined: Thu, 4. May 06, 12:07
x3tc

[TiP][49] 286631

Post by Alex Vanderbilt » Fri, 1. Oct 10, 13:49

<RetVar> = get maximum, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>

<RetVar> = Gibt den höchsten der angegebenen ganzzahligen Werte (Integer) zurück.
<Var/Number> = Bis zu 5 ganze Zahlen können für die Bewertung eingetragen werden. Diese können als Variable, die einen numerischen, ganzzahligen Wert (Integer) enthält, eingetragen werden.

Gibt die höchste der angegebenen, ganzzahligen Werte zurück.

Alle <Var/Number>-Einträge müssen 'integer' (DATATYP_INT), also ganzzahlig, sein. Es ist nicht möglich, Strings in diesem Kommando zu verwenden.

Der Wert kann entweder als einfache Zahl, zum Beispiel 506, oder aber als Variable, zum Beispiel $highest.value.1, $highest.value.2 und so weiter, die dann das Ergebnis einer Berechnung in einem anderen Skript darstellen, eingegeben werden, um den höchsten Wert zu ermitteln.

Beispiel #1:

$highest.value = get maximum, 16, 203, 87, 506, 111

In diesem Beispiel entspricht $highest.value dem Wert 506.

Beispiel #2:

$highest.value = get maximum, 16, $integer.1, 87, $integer.2, 111

In diesem Beispiel würde $highest.value dem höchsten Wert aller <Var/Number> entsprechen. Man kann die Eingabe von direkt angegebenen Integern und Integer beinhaltenden Variablen mischen.


Zu finden unter:
  • »» General Commands
    <RetVar> = get maximum, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>, <Var/Number>
Last edited by Alex Vanderbilt on Sat, 2. Oct 10, 17:06, edited 1 time in total.

mark_a_condren
Posts: 1385
Joined: Wed, 3. Aug 05, 05:05
x3tc

Post by mark_a_condren » Fri, 1. Oct 10, 16:05

Does the above read better now with the added information regarding being able to enter both integers directly and variables?

Thanks AV, you provided quite a good explanation actually.


Mark

Alex Vanderbilt
Winner X3 Sektorquest
Posts: 2119
Joined: Thu, 4. May 06, 12:07
x3tc

Post by Alex Vanderbilt » Fri, 1. Oct 10, 16:48

At least for me it does, but you better wait for a comment from someone who know better about scripting than I do.

AV
ImageImageImageImage

User avatar
X2-Illuminatus
Moderator (Deutsch)
Moderator (Deutsch)
Posts: 21598
Joined: Sun, 2. Apr 06, 16:38
x4

Post by X2-Illuminatus » Fri, 1. Oct 10, 20:52

mark_a_condren wrote:You can not enter strings into this command.
'can not' should be changed to 'cannot'.
Die komplette X-Roman-Reihe jetzt als Kindle E-Books! (Farnhams Legende, Nopileos, X3: Yoshiko, X3: Hüter der Tore, X3: Wächter der Erde)

Neuauflage der fünf X-Romane als Taschenbuch

The official X-novels Farnham's Legend and Nopileos as Kindle e-books! (NOW also available: X3: Yoshiko!)

mark_a_condren
Posts: 1385
Joined: Wed, 3. Aug 05, 05:05
x3tc

Post by mark_a_condren » Sat, 2. Oct 10, 07:49

X2-Illuminatus wrote:
mark_a_condren wrote:You can not enter strings into this command.
'can not' should be changed to 'cannot'.
Done.

Mark

Post Reply

Return to “MSCI Reference”