-
Notifications
You must be signed in to change notification settings - Fork 736
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Add a ace_cargo_space attribute to vehicles to alter how much cargo they can carry. - Add an ace_cargo_size attribute to objects to alter how much cargo space they consume. - Add two public functions `fnc_setSize.sqf` and `fnc_setSpace.sqf` to update the cargo size/space respectively of any given object. - Deprecate cargo makeLoadable module and public function. - Added some macros to get the space/size of a config, making code more readable in places.
- Loading branch information
Showing
18 changed files
with
295 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
class Cfg3DEN { | ||
class Object { | ||
class AttributeCategories { | ||
class ace_attributes { | ||
class Attributes { | ||
class GVAR(space) { | ||
displayName = CSTRING(space_edenName); | ||
tooltip = CSTRING(space_edenDesc); | ||
property = QGVAR(space); | ||
control = "Edit"; | ||
|
||
expression = QUOTE([ARR_2(_this,_value)] call DFUNC(setSpace);); | ||
defaultValue = QUOTE(GET_NUMBER(configFile >> 'CfgVehicles' >> typeOf _this >> QQGVAR(space),0)); | ||
|
||
validate = "number"; | ||
condition = "objectHasInventoryCargo"; | ||
typeName = "NUMBER"; | ||
}; | ||
class GVAR(size) { | ||
displayName = CSTRING(size_edenName); | ||
tooltip = CSTRING(size_edenDesc); | ||
property = QGVAR(size); | ||
control = "Edit"; | ||
|
||
// Expression only runs on the server, must handle actions for all machines and future JIPs (Why BI?!) | ||
expression = QUOTE([ARR_2(_this,_value)] call DFUNC(setSize);); | ||
defaultValue = QUOTE(GET_NUMBER(configFile >> 'CfgVehicles' >> typeOf _this >> QQGVAR(size),-1)); | ||
|
||
validate = "number"; | ||
condition = "1-objectBrain"; | ||
typeName = "NUMBER"; | ||
}; | ||
}; | ||
}; | ||
}; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.