메소드 | 설명 | |
---|---|---|
addResource ( String name, float fillMaxUnits ) : void |
Add a resource, by units, setting/adjusting fill and max units by the units specified
|
|
addResource ( string name, float fill, float max ) : void |
Add a resource, by units, setting/adjusting fill and max units by the units specified
|
|
addResourceByVolume ( String name, float cubicMetersTotalFilled ) : void |
Add a resource, by volume, setting/adjusting fill and max units by the volume specified
|
|
addResourceByVolume ( string name, float cubicMetersFilled, float totalCubicMeters ) : void |
Add a resource, by volume, setting/adjusting fill and max units by the volumes specified
|
|
removeResource ( String name ) : void |
Remove a resource from the list entirely
|
|
removeResource ( String name, float removeFromMax ) : void |
Remove a specified number of units from the resource maximum; if fill>max after this, fill will be set to max. If max==0, resource will be removed from list entirely
|
|
removeResource ( String name, float removeFromFill, float removeFromMax ) : void |
Remove a specified number of units from the resource fill and maximum values; if fill>max after this, fill will be set to max. If max==0, resource will be removed from list entirely
|
|
setResource ( string name, float fill, float max ) : void |
Blindly set the quanity of a resource. Adds new resource if not present, removes resource if present and max==0.
|
|
setResourcesToPart ( Part part ) : void |
Actually set the resources from this list to the input part; if the current part resources match this list exactly they will be updated in-place, else all resources from the part will be cleared and the new list of resources added.
|
public addResource ( String name, float fillMaxUnits ) : void | ||
name | String | |
fillMaxUnits | float | |
리턴 | void |
public addResource ( string name, float fill, float max ) : void | ||
name | string | |
fill | float | |
max | float | |
리턴 | void |
public addResourceByVolume ( String name, float cubicMetersTotalFilled ) : void | ||
name | String | |
cubicMetersTotalFilled | float | |
리턴 | void |
public addResourceByVolume ( string name, float cubicMetersFilled, float totalCubicMeters ) : void | ||
name | string | |
cubicMetersFilled | float | |
totalCubicMeters | float | |
리턴 | void |
public removeResource ( String name, float removeFromMax ) : void | ||
name | String | |
removeFromMax | float | |
리턴 | void |
public removeResource ( String name, float removeFromFill, float removeFromMax ) : void | ||
name | String | |
removeFromFill | float | |
removeFromMax | float | |
리턴 | void |
public setResource ( string name, float fill, float max ) : void | ||
name | string | |
fill | float | |
max | float | |
리턴 | void |