Back to Index | Page generated: Dec 20, 2024, 7:22:09 AM |
from Expansion Manager's OXP list | from Expansion Manifest | |
---|---|---|
Description | This equipment uses a special scan to find out the content of the cargo containers. | This equipment uses a special scan to find out the content of the cargo containers. |
Identifier | oolite.oxp.Okti.CargoScanner | oolite.oxp.Okti.CargoScanner |
Title | Cargo Scanner | Cargo Scanner |
Category | Equipment | Equipment |
Author | Okti, timer | Okti, timer |
Version | 1.12 | 1.12 |
Tags | ||
Required Oolite Version | ||
Maximum Oolite Version | ||
Required Expansions | ||
Optional Expansions | ||
Conflict Expansions | ||
Information URL | http://wiki.alioth.net/index.php/Cargo_Scanner_OXP | n/a |
Download URL | https://wiki.alioth.net/img_auth.php/f/f3/CargoScanner.oxz | n/a |
License | CC-BY-NC-SA 3.0 | CC-BY-NC-SA 3.0 |
File Size | n/a | |
Upload date | 1610873512 |
Also read http://wiki.alioth.net/index.php/Cargo%20Scanner
== Cargo Scanner == All cargo pods have an RFID chip that defines the content of cargo pods. All ships by Law must have a Cargo Reader which logs cargo pods in and out of the ship. This equipment is a long range RFID Scanner that uses a special scan to find out the content of the cargo containers. Original idea - Okti. http://wiki.alioth.net/index.php/Cargo_Scanner_OXP == Usage == Just acquire cargo container as your target. == License == This OXP is released under the Creative Commons Attribution - Non-Commercial - Share Alike 3.0 license == Changes == v1.12 2020-02-09 - Refactoring and fix some problems in code (thanks to Rustem)
Name | Visible | Cost [deci-credits] | Tech-Level |
---|---|---|---|
Cargo Scanner | yes | 10000 | 10+ |
Sell Cargo Scanner | yes | 150 | 10+ |
Path | |
---|---|
Scripts/cargo-scanner.js | 'use strict'; this.name = 'Cargo Scanner'; this.shipTargetAcquired = function(target) { if ( ! target.isShip || ! target.isCargo || target.shipUniqueName || target.isPiloted || player.ship.equipmentStatus('EQ_CARGO_SCANNER') !== 'EQUIPMENT_OK' ) { return; } var tc = target.commodity; if ( tc && tc !== 'goods' ) { var ca = +target.commodityAmount; target.shipUniqueName = displayNameForCommodity(tc) + ( ca === 1 ? '' : ' ['+ca+']' ); } else { target.shipUniqueName = 'Unknown'; } }; this.playerBoughtEquipment = function(equipment) { if ( equipment === 'EQ_CARGO_SCANNER_REMOVER' ) { player.ship.removeEquipment('EQ_CARGO_SCANNER_REMOVER'); player.ship.removeEquipment('EQ_CARGO_SCANNER'); player.credits += ( EquipmentInfo.infoForKey('EQ_CARGO_SCANNER').price * 0.06 ); } }; |