chessmaster42 / cws_injury

Chessmaster's Wounding System for Arma 3
Other
2 stars 1 forks source link

Script version initialization #18

Open GRUBES opened 10 years ago

GRUBES commented 10 years ago

Is there a way to run this as script-only, without the mod?

I tried the following:

  1. Extract 1.1.4 zip
  2. Copy src/addons/cws_injury and chessmastersCommonLibrary into mission directory
  3. Add
#include "cws_injury\cfgFunctions.hpp"
#include "cws_injury\rscTitles.hpp"

to description.ext

  1. Export mission to multiplayer and host local multiplayer game -> Script was never initialized

After this failed, I simply enabled the mod, and it worked as expected. Is this just the mod running?

chessmaster42 commented 10 years ago

In description.ext you have to include those inside of CfgFunctions and RscTitles blocks like this:

class CfgFunctions
{
    #include "cws_injury\cfgFunctions.hpp"
};

class RscTitles
{
    #include "cws_injury\rscTitles.hpp"
};

Let me know if that works for you. If not try to get my a log file on pastebin.com and I'll figure it out.

GRUBES commented 10 years ago

In description.ext, if I put the #include directives inside those classes, I get an error that each class is already defined. Searching our framework for where that might happen; will update later.

Follow-up question: Do I need both the cws_injury folder and the library folder for the script-only version? Or can I get away with just cws_injury?

TheLukio commented 8 years ago

Grubes - depending on the framework you already have a CfgFunctions class defined, just add the include in there.