- Joined
- Jul 22, 2016
- Messages
- 76
- Reaction score
- 17
I have underlined below what I think is the core of my problem.
I am trying to set up a ship with four turrets each on a rail rotator that allows you to use 5 inner ship remotes to send one of five commands "Even", "Starboard", "Dorsal", "Port", "Ventral". This would allow you to somewhat increase your firepower towards a given direction, obviously this is more an RP ability than actually useful, but still would be cool to implement. Images of what I am attempting below:
However, I am running into problems with getting the rotator logic working. The conceptual issue I am having is that unlike with standard rails everything is relative. I can't (so far as I know) have logic set the rotation to "45 degrees clockwise from arbitrary orientation" rather it is always "45 degrees clockwise from current orientation". This creates three problems.
The second problem I feel like I've more or less gotten a handle on despite making my brain hurt a bit The third problem is super easy to solve with standard rails and entity location, but I'm much less certain with rail rotators. Is this something where I need to set up a button next to the rail rotator and it will have to count the 45 degree rotations and send a signal to an AND block (1) when the correct numer of rotations have been completed? Then the inner ship remotes would each go to AND blocks (2-5) that require both their respective inner ship remotes and that original AND block (1) in order tell the turrets to rotate?
I am trying to set up a ship with four turrets each on a rail rotator that allows you to use 5 inner ship remotes to send one of five commands "Even", "Starboard", "Dorsal", "Port", "Ventral". This would allow you to somewhat increase your firepower towards a given direction, obviously this is more an RP ability than actually useful, but still would be cool to implement. Images of what I am attempting below:
Code:
From the bow.
Even:
T T
O------O
| |
O------O
T T
Starboard:
T
TO------O
| |
TO------O
T
Dorsal:
T T
O------O
| |
TO------OT
Port:
T
O------OT
| |
O------OT
T
Ventral:
TO------OT
| |
O------O
T T
- I need to have the ship turrets rotation on being loaded be the same as the rotation I have setup the logic to assume they are.
- I need memory set up to remember what the current rotation is so that the logic can translate the player inputing "Rotate to Port" to "Rotate 45 degrees" or "Rotate 90 degrees" or "Do not rotate" depending on the prior turret position.
- I need to figure out the logic to not accept rotation commands until all turrets are finished rotating.
The second problem I feel like I've more or less gotten a handle on despite making my brain hurt a bit The third problem is super easy to solve with standard rails and entity location, but I'm much less certain with rail rotators. Is this something where I need to set up a button next to the rail rotator and it will have to count the 45 degree rotations and send a signal to an AND block (1) when the correct numer of rotations have been completed? Then the inner ship remotes would each go to AND blocks (2-5) that require both their respective inner ship remotes and that original AND block (1) in order tell the turrets to rotate?
Last edited: