|
|
 |
View previous topic :: View next topic |
 |
|
|
|
|
Author |
Message |
|
|
|
|
|
mark_a_condren

Joined: 03 Aug 2005 Posts: 1384 on topic Location: Newcastle - Australia

|
Posted: Wed, 10. Nov 10, 17:52 Post subject: <RetVar/IF><RefObj> get max amount of ware <Var/Ware> in cargo bay |
|
|
[skip|else] if [not]|while [not]| <RetVar/IF> = <RefObj> get max amount of ware <Var/Ware> in cargo bay
[skip|else] if [not]|while [not]| = The possible 'Conditional' statements that can be used with this command.
<RetVar/IF> = RetVar is if you want to save the quantity to a variable. IF will check to see if the ware can be placed in the cargobay and return True / False.
<RefObj> = The 'Object' (Ship/Station) that the command is to be run on.
<Var/Ware> = What you want to know how much of would fit into an empty cargobay.
Use this command to check how much of an item would fit into a cargobay if the cargobay was empty. This command if run on a station that has set limits for particular wares will take these limits into account and only report on the available space assigned for that ware.
Example:
$target = get tracking aim
If $target is of class ship
| $max.amount = $target get max amount of ware Space Fuel in cargo bay
| IF $max.amount > 0
| | $message = sprintf: fmt='Maximum amount for Space Fuel is %s', $max.amount, null, null, null, null
| | display subtitle text: text=$message duration=5000 ms
| end
end
This will get the players tracking aim and if it is a ship it will check to see how much Space Fuel it can carry in its cargobay. If it can carry Space Fuel it will display the subtitle $message for 5 seconds. The message will contain the $max.amount of Space Fuel that would fit into an empty cargobay.
Command Location:
»» Trade Commands
»» for Ships and Stations
<RetVar/IF><RefObj> get max amount of ware <Var/Ware> in cargo bay
|
|
|
|
|
|
|
Back to top |
|
|
|
 |
|
|
|
|
|
X2-Illuminatus Moderator (Deutsch)

 
Joined: 02 Apr 2006 Posts: 14893 on topic

|
Posted: Sat, 27. Nov 10, 00:03 Post subject: [TiP][49] 291048 |
|
|
[skip|else] if [not]|while [not]| <RetVar/IF> = <RefObj> get max amount of ware <Var/Ware> in cargo bay
[skip|else] if [not]|while [not]| = Die möglichen bedingten Anweisungen, die mit diesem Befehl genutzt werden können.
<RetVar/IF> = Nutze RetVar, wenn du die Anzahl in einer Variable speichern möchtest. IF hingegen wird überprüfen, ob eine Ware in den Frachtraum passt und TRUE / FALSE (wahr / falsch) zurückgeben.
<RefObj> = Das 'Objekt' (Schiff / Station), auf dem der Befehl ausgeführt werden soll.
<Var/Ware> = Die Ware, von der du die Anzahl, die in einen leeren Frachtraum passt, ermitteln möchtest.
Nutze diesen Befehl, um zu überprüfen, welche Menge einer Ware in einen Laderaum passt, wenn dieser leer ist. Wenn dieser Befehl auf einer Station ausgeführt wird und auf dieser Grenzen für bestimmte Waren festgelegt sind, so wird der Befehl diese Grenzen berücksichtigen.
Beispiel:
$target = get tracking aim
If $target is of class ship
| $max.amount = $target get max amount of ware Raumsprit in cargo bay
| IF $max.amount > 0
| | $Nachricht = sprintf: fmt='Die maximale Menge an Raumsprit ist %s', $max.amount, null, null, null, null
| | display subtitle text: text=$Nachricht duration=5000 ms
| end
end
Dies wird überprüfen, welche Menge an Raumsprit in den Laderaum des Ziels des Spielers (wenn es ein Schiff ist) passt. Wenn Raumsprit hinein passt, wird der Untertitel $Nachricht für 5 Sekunden angezeigt. Die Nachricht enthält die maximale Menge $max.amount an Raumsprit, die in einen leeren Frachtraum passen würde.
Zu finden unter:
»» Trade Commands
»» for Ships and Stations
<RetVar/IF><RefObj> get max amount of ware <Var/Ware> in cargo bay
|
|
|
|
|
|
|
Back to top |
|
|
|
 |
|
|
|
|
|
|
|
 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum
|
 |
|
|
|
|
|