Results 1 to 8 of 8

Thread: Extending Objects

  1. #1

    Extending Objects

    Hello,

    Today is my 3rd day of learning about sqf, and I am trying to understand how to extend an object. I want to extend the Land_Barrel_sand and basically make it transportable via ACE's cargo module.

    My config.cpp:
    Code:
    class CfgVehicles
    {
    	class Land_Barrel_sand;
    	
    	class Land_Barrel_transport : Land_Barrel_sand
    	{
    		ACE_canBeCargo = 1;
    	};
    };
    I am trying to spawn the barrel via this line in my init.sqf:

    Code:
    _barrel = "Land_Barrel_transport" createVehicle(getMarkerPos "barrel_spawn");
    And here is the line that I see in the rpt file that is causing concern:
    Code:
    Cannot create non-ai vehicle Land_Barrel_transport,
    Can someone educate me as to the error of my ways?

  2. #2
    Did you try creating a Land_Barrel_sand instead?
    If it doesnt give you an error then chances are your CPP is not loading.
    Where is your CPP anyway ?

  3. #3
    you need cfgpatches also at top
    also you need new displayname in your new barrel because scope is public for
    class Land_Barrel_sand: Thing
    {
    scope = 2;
    vehicleClass = "misc";
    destrType = "DestructNo";
    model = "\CA\Structures\Misc\Armory\Barels\barrel_sand ";
    icon = "\Ca\Structures\Misc\Armory\Data\Icons\barrel_CA.p aa";
    mapSize = 0.7;
    displayName = "Plastic barrel (sand)";
    };
    this mean you will have 2 * Plastic barrel (sand) because you have inherited all that it is and no change to display name.
    A chopper cup of Coffee in a chopper coffee pot
    TOH Now with added Coffee
    http://www.helpivanmartin.org/

  4. #4
    Private First Class
    Join Date
    Aug 21 2012
    Posts
    25
    Author of the Thread
    Quote Originally Posted by [APS]Gnat View Post
    Did you try creating a Land_Barrel_sand instead?
    If it doesnt give you an error then chances are your CPP is not loading.
    Where is your CPP anyway ?
    I think I am making a big mistake here. I am editing the mission via sqf scripts in the saved folder and that is where I had the config.cpp. But lightning just struck me and I realized that the config.cpp is meant for addons and belongs into the @addonname folder which then has to be loaded by the game first. Can I just create an @addon_name folder and place a config.cpp in it, or does it have to be turned into a binary first?

    ---------- Post added at 11:43 ---------- Previous post was at 11:41 ----------

    Quote Originally Posted by Thromp View Post
    you need cfgpatches also at top
    also you need new displayname in your new barrel because scope is public for

    this mean you will have 2 * Plastic barrel (sand) because you have inherited all that it is and no change to display name.
    Thank you sir, I just learned something new. If I wanted to see all of the classes and their configurations would I have to decompile a config.bin somewhere?

  5. #5
    dev heaven or ofpec i believe you can find the configs
    there is a post in tools with a config reader somewhere too here on bis forums

  6. #6
    I always keep a copy of the ALLINONE config from DevHeaven live in my text editor for constant reference.

  7. #7
    Private First Class
    Join Date
    Aug 21 2012
    Posts
    25
    Author of the Thread
    Quote Originally Posted by [APS]Gnat View Post
    I always keep a copy of the ALLINONE config from DevHeaven live in my text editor for constant reference.
    Where can one find this ALLINONE config, I was unable to google it on dev-heaven.

  8. #8

Similar Threads

  1. Extending Objects
    By krumpo in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 2
    Last Post: Aug 21 2012, 23:47
  2. Extending the campaign?
    By Jedra in forum TAKE ON HELICOPTERS : MISSIONS - Editing & Scripting
    Replies: 7
    Last Post: Dec 31 2011, 01:22
  3. Extending Mortar Range?
    By azz_er in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 3
    Last Post: Jun 28 2011, 15:08
  4. Extending borders
    By LockJaw-65- in forum ARMA 2 & OA : TERRAIN - (Visitor)
    Replies: 1
    Last Post: Jul 5 2009, 22:32
  5. Extending license
    By Turek2CDC in forum OFP : O2 MODELLING
    Replies: 2
    Last Post: Jul 17 2002, 12:11

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •