Skelt 10 Posted October 14, 2011 just trying to write a script to create all my modules at the start of the mission, but it doesn't appear to be working. It's the very first thing the init.sqf runs and has a waituntil {scriptdone _mod}; and it's also only run by the server. I'm creating the modules via: //create Functions Module _function = "FunctionsManager" createVehicle [0,0,0]; I don't get any errors on startup. Thanks, Skelt, aka Bones Share this post Link to post Share on other sites
sxp2high 22 Posted October 14, 2011 Hi, createVehicle is not correct for modules. It has to be createUnit: _ModuleGroup = createGroup sideLogic; _Module = _ModuleGroup createUnit ["FunctionsManager", [0,0,0], [], 0, "NONE"]; Share this post Link to post Share on other sites
Skelt 10 Posted October 14, 2011 Thank you, that would be my issue.. Thanks! Share this post Link to post Share on other sites
Skelt 10 Posted October 14, 2011 everything looks good, but still no modules: //Server check if (!isServer) exitwith {}; _moduleGroup = createGroup sideLogic; _function = _moduleGroup createUnit ["FunctionsManager",[0,0,0],[],0,"NONE"]; _ambient = _moduleGroup createUnit ["Alice2Manager",[0,0,0],[],0,"NONE"]; _ambient1 = _moduleGroup createUnit ["BIS_animals_Logic",[0,0,0],[],0,"NONE"]; _particles = _moduleGroup createUnit["WeatherParticlesmanager",[0,0,0],[],0,"NONE"]; _server = _moduleGroup createUnit ["Logic",[0,0,0],["server = this"],0,"NONE"]; _aceGroup = createGroup sideLogic; _wounds = _aceGroup createUnit ["ACE_Wounds_Logic",[0,0,0],[],0,"NONE"]; _wounds1 = _aceGroup createUnit ["ACE_Wounds_EveryoneMedic",[0,0,0],[],0,"NONE"]; _wounds2 = _aceGroup createUnit ["ACE_Wounds_FullHeal",[0,0,0],[],0,"NONE"]; _spare = _aceGroup createUnit ["ace_sys_repair_tyres",[0,0,0],[],0,"NONE"]; _reqAce = _aceGroup createUnit ["ACE_Required_Logic",[0,0,0],[],0,"NONE"]; _supportGroup = createGroup sideLogic; _artyLogic = _supportGroup createUnit ["BIS_ARTY_Logic",[0,0,0],["m119Batt = this"],0,"NONE"]; _arty = _supportGroup createUnit ["BIS_ARTY_Virtual_Artillery",[0,0,0],["vp1 = this"],0,"NONE"]; _arty1 = _supportGroup createUnit ["BIS_ARTY_Virtual_Artillery",[0,0,0],["vp2 = this"],0,"NONE"]; _arty2 = _supportGroup createUnit ["BIS_ARTY_Virtual_Artillery",[0,0,0],["vp3 = this"],0,"NONE"]; _artyLogic synchronizeObjectsAdd ["vp1","vp2","vp3"]; hint "Modules have Run"; I'm going to try a few more things, I'm not sure if I defined the init's correctly, however it doesn't error in the editor, nor does it post anything to the log. So gonna play around with it a bit more. Thanks, Skelt, aka Bones Share this post Link to post Share on other sites
blakeace 11 Posted October 14, 2011 (edited) I think you need to use createCenter first, like when creating soldiers I believe. http://community.bistudio.com/wiki/createCenter E.g. _LogicCenter = createCenter sideLogic; _moduleGroup = createGroup _LogicCenter; Hope this helps Blake. Edited October 14, 2011 by blakeace Share this post Link to post Share on other sites
sxp2high 22 Posted October 15, 2011 Yep that's right, a center is required. You also have to create most modules on both server and client. Not server only. The WeatherParticlesmanager at least, for sure. Maybe some modules won't work this way. I know that the Weather/Clouds module didn't work for me by creating the module afterwards. I ended up including the module into my mission (The SQS files). Share this post Link to post Share on other sites
Skelt 10 Posted October 15, 2011 LoL so simple... and I should most definitely have known that. yeah thinking of it, I doubt it would cause any issues if the modules were run on on systems. Thanks guys. Share this post Link to post Share on other sites