mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Cargo - Add documentation on adding cargo via config (#9994)
* Fix bag of holdings in cargo * Update CfgVehicles.hpp * Update CfgVehicles.hpp * Revert space changes
This commit is contained in:
parent
a31608073e
commit
db2bf60c28
@ -48,15 +48,7 @@ class CfgVehicles {
|
||||
class Car: LandVehicle {
|
||||
GVAR(space) = 4;
|
||||
GVAR(hasCargo) = 1;
|
||||
class ACE_Cargo {
|
||||
/*
|
||||
class Cargo {
|
||||
class ACE_medicalSupplyCrate {
|
||||
type = "ACE_medicalSupplyCrate";
|
||||
amount = 1;
|
||||
};
|
||||
};*/
|
||||
};
|
||||
class ADDON {};
|
||||
};
|
||||
|
||||
class Tank: LandVehicle {
|
||||
@ -75,7 +67,7 @@ class CfgVehicles {
|
||||
GVAR(hasCargo) = 1;
|
||||
};
|
||||
|
||||
// HEMTTs - Default at 10, some variants are altered based on model size and/or expected level of free space inside.
|
||||
// HEMTTs - Default at 30, some variants are altered based on model size and/or expected level of free space inside.
|
||||
class Truck_01_base_F: Truck_F {
|
||||
GVAR(space) = 30;
|
||||
};
|
||||
@ -523,6 +515,7 @@ class CfgVehicles {
|
||||
class EventHandlers {
|
||||
class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {};
|
||||
};
|
||||
|
||||
GVAR(space) = 3;
|
||||
GVAR(hasCargo) = 1;
|
||||
GVAR(size) = 3;
|
||||
|
@ -47,6 +47,24 @@ class CfgVehicles {
|
||||
<p>ace_cargo_hasCargo and ace_cargo_canLoad are only needed if you aren't inheriting from any of BI base classes or if you are trying to disable loading for a specific vehicle / object.</p>
|
||||
</div>
|
||||
|
||||
### 1.3 Adding predefined cargo via config
|
||||
|
||||
```cpp
|
||||
class CfgVehicles {
|
||||
class yourVehicleClass {
|
||||
ace_cargo_space = 4; // Add if necessary
|
||||
ace_cargo_hasCargo = 1; // Add if necessary
|
||||
class ace_cargo {
|
||||
class cargo {
|
||||
class ACE_medicalSupplyCrate { // Doesn't have to have the same name as the item you're adding
|
||||
type = "ACE_medicalSupplyCrate";
|
||||
amount = 1;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
```
|
||||
|
||||
## 2. Events
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user