repl.it
@MinecraftMrGabe/

Stormworks Plesiosub Control

Lua

-- Forked from https://repl.it/@mgmchenry/Stormworks-Quad-Tilt-Rotor-Flight-Control-and-Stability

fork
loading
Files
  • main.lua
  • howdidIgetanan.lua
  • LuaCube.lua
  • QuadFlightControl.V0.06.13.lua
  • Stormworks Lua Help.txt
  • Stormworks_Stub.lua
  • SW_Cube.lua
  • SW_FlightVis.lua
  • SW_PlesiosubControl.lua
  • SW_QuadSubControl.lua
main.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
-- Stormworks Lua module Test Helper Example Thing
-- V 0.4 Michael McHenry 2019-06-07
inValues, outValues, inBools, outBools = {}, {}, {}, {}
table.unpack = table.unpack or unpack

-- Set up SW environment
dofile("Stormworks_Stub.lua")
dofile("howdidIgetanan.lua")

runTest(function() onTick() end, "onTick")
--runTest(function() onDraw() end, "onDraw")
-- Those return without doing anything because inValues are nil

-- Set an inValue so it continues to the error:
inValues[1] = 0
-- actually, set them all :P
for i=1,32 do
  inValues[i]=0
end

runTest(function() onTick() end, "onTick")
--runTest(function() onDraw() end, "onDraw")

-- Set rps high enough to trigger hover code
inValues[29] = 80

runTest(function() onTick() end, "onTick")
--runTest(function() onDraw() end, "onDraw")

for i=1,32 do
  inValues[i]=1
end
inValues[29] = 80

runTest(function() onTick() end, "onTick")
--runTest(function() onDraw() end, "onDraw")