Tile - YChargeable - Set Current Charge – Ylands

From Bohemia Interactive Community
Jump to navigation Jump to search
m (YlandsClassyBot moved page Ylands Tile - Charge entity to Ylands:Tile - YChargeable - Set Current Charge: New Structure)
No edit summary
(One intermediate revision by the same user not shown)
Line 1: Line 1:
[[Image:Ylands_Tile_-_Entity_charge.png]]
<!---
*Allows to get/set '''current''' total amount of charge of an entity
THIS PAGE WAS GENERATED AUTOMATICALLY; DO NOT EDIT IT, OTHERWISE YOUR CHANGES WILL BE LOST DURING FUTURE UPDATE.
-->
== Set Current Charge(Entity, Value) ==


[[File:YlandsTile-1047.png]]


[[Image:Ylands_Tile_-_Entity_charge_add.png]]
<pre>static setCurrentCharge(target: YEntity, value: number): void;</pre>
*Allows to '''increase''' charge of target entity
=== Parameters ===


==== target ====


[[Image:Ylands_Tile_-_Entity_charge_remove.png]]
==== value ====
*Allows to '''decrease''' charge from target entity


=== Availability ===


=Notes=
[[Ylands:Tile Availability - Server|Server]]
*Works for "chargeable" items (e.g Mining drill)
 
*Works also for engines
=== Description ===
*Power cells cannot be recharged from a script, only depleted
 
*Entering negative number as amount will inverse the instruction effect
Allows to set current power charge of target entity.




Line 23: Line 27:


[[Category: Instructions]]
[[Category: Instructions]]
[[Category: Ylands 0.10]]

Revision as of 12:16, 12 November 2021