Nexus Skirmisher
Nexus Modding => Mod Development / Released Mods => Topic started by: SnakeLegend on February 13, 2010, 06:01:06
-
Like topic said, i tried to get some stuffs active but somehow it is like not in working condition.
-
Are you trying to mod the ships used in the game's campaign? Or ships used in a specific mission in a mod you're creating?
-
We'll need some more details, I fear... what exactly are you trying to do?
-
Well i am trying to get the Campaigns ships working like god mode and tried to mod some scripts that was told online by some fellows.
Tried but i am not sure if i did it correctly.
-
You want to make all your ships indestructible? Why?
Anyway, you could bump up the HpMax values in universetacticstacticstypes.ini for the classes you use, but that would also increase the HP of all hostile human ships. You could also edit each mission file in universemissionsepisodes to include the following code snippet:
RULE event SceneInit
:action
GetMachine("GodMode"):ChangeState(default, 0);
:end
END
MACHINE "GodMode"
STATE default
RULE event Tick
:action
SelectEx((s.ship | s.wreck) & s.race=#race_player,
s.this:damage := 0;
);
:end
END
TICK 0.1
END
END
Or better yet, save that snipped as a seperate file in the same folder as "godmode.inc" and just insert [code=orange]#include "godmode.inc"[/color] in each mission file after its SceneInit event.
This script would try to keep all player ships at maximum health. It would only fail, if you encounter an enemy weapon capable to destroy your in one shot.
-
Or maybe add this to the SceneInit rule...
FleetPlayer:=GetFreeSel();
SelectShips(FleetPlayer,S.race=#race_Player);
ExecList(FleetPlayer,
SetUndamageable(S.this,1);
);
As Arparso said, you caould also have it as an 'include' file.
-
SetUndamageable... ah, didn't know that command :)