<RetVar> = get maintype of ware <Var/Ware>

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

Moderators: Scripting / Modding Moderators, MSCI Moderators

Locked
mark_a_condren
Posts: 1468
Joined: Wed, 3. Aug 05, 05:05
x3tc

<RetVar> = get maintype of ware <Var/Ware>

Post by mark_a_condren » Thu, 2. Dec 10, 17:46

<RetVar> = get maintype of ware <Var/Ware>


<RetVar> = The command return will be stored in this variable.
<Var/Ware> = The ware that you want the maintype of.


Each ware belongs to a main and sub-category called maintype and subtype.
This command returns the specified ware's numerical 'maintype'.


Example:

$ware.maintype = get maintype of ware Fragmentation Bomb Launcher

As a Fragmentation Bomb Launcher is a laser or weapon, it is maintype 8 , so $ware.maintype will be 8


Additional Information:

A list of Maintypes and their Subtypes can be found here.


Command Location:

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

[TiP][49] 292502

Post by X2-Illuminatus » Wed, 8. Dec 10, 20:41

<RetVar> = get maintype of ware <Var/Ware>


<RetVar> = Der Rückgabewert des Befehls wird in dieser Variable gespeichert.
<Var/Ware> = Die Ware, deren Maintype du ermitteln möchtest.


Jede Ware gehört zu einer Haupt- und einer Unterkategorie, die "Maintype" und "Subtype" genannt werden.
Dieser Befehl gibt den nummerischen Wert des Maintypes der gewählten Ware zurück.


Beispiel:

$ware.maintype = get maintype of ware Splitterbombenwerfer

Da ein Splitterbombenwerfer ein Laser bzw. eine Waffe ist, ist der maintype 8, somit wird $ware.maintype gleich 8 sein.


Zusätzliche Information:

Eine Liste der Maintypes und Subtypes findet sich hier.


Zu finden unter:

Locked

Return to “MSCI Reference”