Skip to content

Commit 7c8b448

Browse files
Merge branch 'browncoat-mission' of https://github.com/cortex-command-community/Cortex-Command-Community-Project into browncoat-mission
2 parents adeb24a + e7b4c9b commit 7c8b448

File tree

2 files changed

+13
-8
lines changed

2 files changed

+13
-8
lines changed

Data/Base.rte/Scripts/Global/DebugFunctions.lua

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,21 @@ function DebugFunctionsScript:UpdateScript()
2626
end
2727
end
2828

29+
for act in MovableMan.Actors do
30+
if act:IsPlayerControlled() then
31+
self.lastControlledActor = act;
32+
end
33+
end
34+
2935
-- Hold Alt to do any of these
3036
if UInputMan.FlagAltState then
37+
38+
-- Space to teleport last controlled actor to cursor
39+
if UInputMan:KeyPressed(Key.SPACE) then
40+
if self.lastControlledActor then
41+
self.lastControlledActor.Pos = CameraMan:GetScrollTarget(0);
42+
end
43+
end
3144

3245
-- Keypad 9 for HUD Toggle
3346
if UInputMan:KeyPressed(Key.KP_9) then

Data/Browncoats.rte/Activities/RefineryAssault.lua

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -558,14 +558,6 @@ function RefineryAssault:UpdateActivity()
558558
self:ChangeAIFunds(1, 200);
559559
end
560560

561-
-- Brain teleport to cursor
562-
if UInputMan:KeyPressed(Key.SPACE) then
563-
for k, brain in pairs(self.saveTable.playerBrains) do
564-
local pos = CameraMan:GetScrollTarget(0);
565-
brain.Pos = pos;
566-
end
567-
end
568-
569561
-- Invincible brain and infinite gun
570562
if not self.saveTable.debugInvincibleBrain and UInputMan:KeyPressed(Key.KP_6) then
571563
self.saveTable.debugInvincibleBrain = true;

0 commit comments

Comments
 (0)