<RetVar> = <RefObj> get production status: as percentage=<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

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

<RetVar> = <RefObj> get production status: as percentage=<Var/Number>

Post by X2-Illuminatus » Fri, 1. Apr 11, 18:57

<RetVar> = <RefObj> get production status: as percentage=<Var/Number>


<RetVar> = A variable, where the requested information is stored.
<RefObj> = A factory you want to know its current production status.
<Var/Number> = A TRUE or FALSE value or its representing number 1 or 0.


This command returns the current production status of the as <RefObj> selected factory.
If <Var/Number> is TRUE, it will return the percentage of wares that are already in stock of the factory and that are needed for the next production cycle. If <Var/Number> is FALSE, it will just return 1 if the factory has enough resources for the next production cycle, or 0 if it hasn't.


Example:

$station = get player tracking aim
$percentage = $station -> get production status: as percentage=[TRUE]
write to player logbook: printf: fmt='%s has %s percent of wares for the next production cycle in stock.', $station, $percentage, null, null, null
return null

This will return the percentage of wares the player's target station has for the next production cycle in stock.


Command Location:
  • »» Trade Commands
    • »» for Stations
      <RetVar> = <RefObj> get production status: as percentage=<Var/Number>

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

[TiP][49] 299191

Post by X2-Illuminatus » Mon, 2. May 11, 19:39

<RetVar> = <RefObj> get production status: as percentage=<Var/Number>


<RetVar> = Eine Variable, in der die geforderte Information gespeichert wird.
<RefObj> = Eine Fabrik, deren aktuellen Produktionsstatus du wissen möchtest.
<Var/Number> = Ein TRUE (wahr) oder FALSE (falsch) Wert oder die entsprechende Zahl 1 oder 0.


Dieser Befehl gibt den aktuellen Produktionsstatus der als <RefObj> ausgewählten Fabrik zurück.
Wenn <Var/Number> gleich TRUE ist, wird der Prozentwert der Waren zurückgeben, die die Fabrik bereits im Lagerraum hat und für den nächsten Produktionszyklus gebraucht werden. Wenn <Var/Number> gleich FALSE ist, wird nur 1 zurückgegeben, wenn die Fabrik genug Waren für den nächsten Produktionszyklus hat oder 0 wenn nicht.


Beispiel:

$station = get player tracking aim
$percentage = $station -> get production status: as percentage=[TRUE]
write to player logbook: printf: fmt='%s hat %s Prozent der Waren für den nächsten Porduktionszyklus im Lagerraum.', $station, $percentage, null, null, null
return null

Dies gibt den Prozentwert der Waren zurück, die die aktuell vom Spieler als Ziel erfasste Fabrik bereits für den nächsten Produktionszyklus geladen hast.


Zu finden unter:
  • »» Trade Commands
    • »» for Stations
      <RetVar> = <RefObj> get production status: as percentage=<Var/Number>

Locked

Return to “MSCI Reference”