mods needed: all your basic stuff like clockwork, ccvs, trackwork etc. + advanced peripherals and some peripherals
step 1: hull configuration
both turret and gun are using rotation speed controllers, you need to put 2 of those and place the computers facing AWAY from them (example screenshot will be in comments). Then place a seat connected to the hull, preferably right over your turrets rotation axis and not too far away from the cannon mount. You can use Vmod’s “disable collisions” mode on turret and hull to place a seat inside the turret in the way it doesn’t obstruct its movement.
step 2: preparing the turret
when making the turret, make sure that the barrel faces in the z+ direction. place block reader with the arrow pointing at the cannon mount and the goggle link port near the computer (example screenshot in comments again) , assemble the cannon. click with the status goggles on the link port and wear them.
3: code.
run gun_controls.lua on both computers controlling the yaw and pitch, note that those should have different ids. Inside the turret.lua script change the gun_controls_id and turret_controls_id to their corresponding values and run the script on the computer connected to the the goggle link
2024-05-30_14.38.59.png
2024-06-02_14.33.59.png