ThePara 0 Posted May 12, 2005 Hi, I know absolutely nothing about scripts or init sequences of anything so I was wondering if you could help. I'm trying to edit the ORC Naval Infantry config so that the troops start with the helmet camo on instead of off. Does anyone know how to do this? Do I switch a 1 to a 0 or something on the init field in the config or what? Any help is appreciated. I haven't asked for permission yet simply because this is a private thing for me. Thank you. Share this post Link to post Share on other sites
Big Dawg KS 6 Posted May 12, 2005 Well, that all depends, I don't have the pack so I don't know how the scripts work, but no matter how its done it should be really simple to change, why don't you explain more about the config and eventhandlers and scripts? You could copy/paste some parts here... Share this post Link to post Share on other sites
sanctuary 19 Posted May 13, 2005 Untested, but if i give a look to the icp_nav config.cpp , i notice in the definition of some of the soldiers Quote[/b] ]hiddenSelections[] = { "helmcamo1", "med" }; or Quote[/b] ]hiddenSelections[] = { "helmcamo1" }; try to get rid of the part i put in bold and see if it solves your problem, so it should look Quote[/b] ]hiddenSelections[] = { "med" }; or Quote[/b] ]hiddenSelections[] = {}; depending if there are other selections named in the hiddenselections[] lines. Share this post Link to post Share on other sites
ThePara 0 Posted May 13, 2005 I've tried all sorts of different stuff and can't seem to get it to work. I'm assuming it's a function of what's in the scripts/init.sqs files? So here are both of them, I can't make any sense of them but maybe you guys can.. Init: Quote[/b] ]_soldier = _this select 0#Vars _helmetstate = _soldier animationPhase "HelmCamoState" #Wait @ (_helmetstate != _soldier animationPhase "HelmCamoState") or !(alive _soldier) ? !(alive _soldier) : exit if (_helmetstate != _soldier animationPhase "HelmCamoState") then {_helmetstate = _soldier animationPhase "HelmCamoState"; goto "HelmetCheck"} #HelmetCheck if (_helmetstate == 1) then {goto "HelmetCamoOn"} if (_helmetstate == 0) then {goto "HelmetCamoOff"} #HelmetCamoOff _soldier setObjectTexture [0,"\icp_nav\1\setka.paa"]; goto "Wait" #HelmetCamoOn _soldier setObjectTexture [0,""]; goto "Wait" Quote[/b] ]Init2: _soldier = _this select 0 #Vars _helmetstate = _soldier animationPhase "HelmCamoState" #Wait @ (_helmetstate != _soldier animationPhase "HelmCamoState") or !(alive _soldier) ? !(alive _soldier) : exit if (_helmetstate != _soldier animationPhase "HelmCamoState") then {_helmetstate = _soldier animationPhase "HelmCamoState"; goto "HelmetCheck"} #HelmetCheck if (_helmetstate == 1) then {goto "HelmetCamoOn"} if (_helmetstate == 0) then {goto "HelmetCamoOff"} #HelmetCamoOff _soldier setObjectTexture [0,"\icp_nav\1\setka.paa"]; goto "Wait" #HelmetCamoOn _soldier setObjectTexture [0,""]; goto "Wait" Maybe you guys can make some sense of this stuff, thanks for the help. Share this post Link to post Share on other sites
sanctuary 19 Posted May 13, 2005 First As i previously said, delete each <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">"helmcamo1" from each hiddenselection[]=...... lines exactly like i wrote in my previous post. Second delete each occurances of those lines (those lines appear in several nav soldiers definitions) this will remove the action menu entry about the helmet camo <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> class animations { class HelmCamoState { type="rotation"; animperiod=.01; selection="brain"; axis="brain"; angle0=0; angle1=1.745; }; }; class UserActions { class HelmCamoOff { displayName="Camouflage helmet"; position="Brain"; radius=0.1; sound={}; condition="this animationPhase ""HelmCamoState"" == 0"; statement="this animate [""HelmCamoState"", 1];"; }; class HelmCamoOn { displayName="Take off helmet camo"; position="Brain"; radius=0.1; sound={}; condition="this animationPhase ""HelmCamoState"" == 1"; statement="this animate [""HelmCamoState"", 0];"; }; }; Third, delete eveywhere it can be found those lines <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> class EventHandlers { Init="[_this select 0] exec ""\icp_nav\scripts\init.sqs"";"; }; Those appear a lot of time in the soldiers definition too. Once you have done it without errors, you will notice that the naval ORCS have always the camo on their helmets. -tested- Share this post Link to post Share on other sites
Big Dawg KS 6 Posted May 13, 2005 FirstAs i previously said, delete each <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">"helmcamo1" from each hiddenselection[]=...... lines exactly like i wrote in my previous post. Second delete each occurances of those lines (those lines appear in several nav soldiers definitions) this will remove the action menu entry about the helmet camo <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> class animations { class HelmCamoState { type="rotation"; animperiod=.01; selection="brain"; axis="brain"; angle0=0; angle1=1.745; }; }; class UserActions { class HelmCamoOff { displayName="Camouflage helmet"; position="Brain"; radius=0.1; sound={}; condition="this animationPhase ""HelmCamoState"" == 0"; statement="this animate [""HelmCamoState"", 1];"; }; class HelmCamoOn { displayName="Take off helmet camo"; position="Brain"; radius=0.1; sound={}; condition="this animationPhase ""HelmCamoState"" == 1"; statement="this animate [""HelmCamoState"", 0];"; }; }; Third, delete eveywhere it can be found those lines <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> class EventHandlers { Init="[_this select 0] exec ""\icp_nav\scripts\init.sqs"";"; }; Those appear a lot of time in the soldiers definition too. Once you have done it without errors, you will notice that the naval ORCS have always the camo on their helmets. -tested- That will work sanctuary but it will disable them from taking it on/off completely, if you still want them to be able to take them on and off, then simply add 1 line to the init: Quote[/b] ]_soldier = _this select 0#Vars _helmetstate = _soldier animationPhase "HelmCamoState" _soldier animate ["HelmCamoState",1] #Wait @ (_helmetstate != _soldier animationPhase "HelmCamoState") or !(alive _soldier) ? !(alive _soldier) : exit if (_helmetstate != _soldier animationPhase "HelmCamoState") then {_helmetstate = _soldier animationPhase "HelmCamoState"; goto "HelmetCheck"} #HelmetCheck if (_helmetstate == 1) then {goto "HelmetCamoOn"} if (_helmetstate == 0) then {goto "HelmetCamoOff"} #HelmetCamoOff _soldier setObjectTexture [0,"\icp_nav\1\setka.paa"]; Â goto "Wait" #HelmetCamoOn _soldier setObjectTexture [0,""]; Â goto "Wait" Share this post Link to post Share on other sites