1. Hey Guest! We're currently translating StarMade. Anyone can translate, if you can, feel free to!
      Dismiss Notice
    2. Interested in helping moderate SMD? We're currently looking for moderators, check out this thread.
      Dismiss Notice

    need "Logical" help with a cannon/beam machinegun

    Discussion in 'Logic' started by Bushmaster6000, Dec 7, 2017.

    1. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      So i have this idea for a logic weapon, a big gun consisting of a line of cannon/beam cannons in a sort of barrel configuration and making it a machinegun (much like a cannon/cannon) but shooting very fast bullets.
      I figure i could achieve this with a very fast logic clock and that activates a string of activation blocks in a series, at least 20 so i could link it to that many computers, but i've hit a snag... i don't know logic.

      Any help would be appreciated, i mean it's almost christmas and i just want some dakka
       
    2. alterintel

      alterintel Moderator

      Joined:
      May 24, 2015
      Messages:
      809
      This may help:


      just link weapon computers instead of lights to the clock outputs.
       
    3. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      Nah must go faster, must go faster. You know because you go slow... you die. I need the blocks to be as fast as that one that is nearly flashing on and off. there's a 4-barrel logic minigun prototype that has a series of wireless activation blocks that doesn't cycle one at a time with a timer but with button switches, thanks to you i got a fast pulsing block but that minigun prototype only has a string of 4 wireless modules that cycles, i need it longer but i got no idea how.

      this is my goto idea right now because my rail area trigger logic didn't work and this feels like my best bet and any help would be appreciated.
       
      #3 Bushmaster6000, Dec 7, 2017
      Last edited: Dec 7, 2017
    4. Captain Skwidz

      Joined:
      Jun 14, 2017
      Messages:
      53
      Sorry about the wall of text but...

      Place down two cannon computers. Place down twenty cannon barrels. Link ten barrels to each computer and slave a computer to the other (the one that will shoot). Place logic components in this order: NOT gate, delay signal, AND gate. Connect the NOT to the delay, the delay to the AND, and the AND to the NOT. Connect the NOT gate to the master cannon computer. Place a button, activator switch, inner ship remote, or other "activator" block and connect that to the AND gate. Place a temporary button connected to the NOT gate and press it. Remove when done. If you chose an inner ship remote, you can "equip" it in flight mode and use it like a normal ship weapon etc. If you turn it on, the cannon will rapidly fire provided you have enough power. You can also change the amount of cannon computers and barrels for different things as well as use different weapons.

      Also here's a basic logic tutorial by GmodismGmodism:
       
      • Like Like x 1
    5. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      Well that isn't what i mean but im gonna thank you anyway Captain 5kwidz for teaching me how to make a burst cannon+cannon. Its my bad for sucking at communicating what i mean, i blame a lack of social skills and laziness, but by fast i mean how cannon+beam weapons have 2x the projectile speed of conventional cannon weapons and having multiples of those to make a logic machinegun (well its more like a burst Autocannon), here's a pic that hopefully helps:
      Starmade_Fast-MG_proj.jpg
      Here i have 20 different weapon groups and activation modules, using the pulse output of a fast clock i want to use logic that activates a series of activation modules 1 at a time per pulse; ie. when i click a button once weapon group 1 fires, when i click again weapon group 2 fires, click again weapon group 3 fires, and so on then at the end it repeats (but i'm not the guy clicking, the fast clock output is). the burst and possible chance of spam jamming is a non issue since i could use delay blocks to stop discrepensies in reloading between the weapon groups.

      My issue is i don't know how to make a string of activation modules like those in the pic turn on 1 at a time and repeat, so that's my actual logic question.
       
    6. Captain Skwidz

      Joined:
      Jun 14, 2017
      Messages:
      53
      Try replacing the activation modules with buttons and connect them in a chain. Put an AND gate at the start and connect the end to the AND. Connect the clock in my last post to the AND as well and connect each button to each master computer. That should give the desired effect. I'll mess with this later.
       
    7. Sachys

      Sachys Hermit.

      Joined:
      Nov 30, 2015
      Messages:
      355
      for a start, do not use activation modules in the way you are.
      what you want is a clock similar to the ones described above, but connecting one of the logic blocks to each computer (in this case a delay would likely be your best bet*). sadly, this limits the clock to a 0.5 second timing on each shot, at which point you'd need to figure out how many individual computer setups would fit into the clock setup you have before any of them has recharged.
      you could of course investigate rail clock builds via the community content, but i think right now theye no better off. two or more layers of the same clock firing off alternately could also work, but may be laggy depending on various factors - never mind the fact you would presumably be aiming and not an AI.
      sorry if thats more help, but its about right *unless things have swifly changed since i was playing with this idea two months back). the best way to learn logic tends to be taking apart something else after a brief window into it (or it was for me).
      good luck! :)


      *contrary to other advice, an OR / NOT / DELAY loop is preferable as the AND block can cause issues becuase it ANDs (this may make more sense when you ken a wee bit more logic).
       
      • Informative Informative x 1
    8. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      ummm... how would i connect your clock to an and block but nevermind it wouldn't be of much help to my situation.

      Ok i'm still getting a sense that i'm not expressing myself right so here it is kindergarden style:

      this is sven's minigun prototype, well just the parts i care about. it might not have been intentional but its firerate seems to be based on how many pulses go into it, not by slow wimpy delays of any sort. see how the wireless blocks are activated in a series:
      1 pulse= 20171209224100_1.jpg
      +1 pulse 20171209224121_1.jpg
      +1 pulse 20171209224158_1.jpg
      +1 pulse 20171209224216_1.jpg and then it repeats.

      the problem is that there's only 4 activation outputs (i know how to use buttons, activation blocks, and wireless remotes so what kind of button to use doesn't help) and i need alot more outputs than that since i plan on using at least 20 plus cannon+slaved beam weapon groups in a line so...
      20171209234925_1.jpg 20171209235007_1.jpg
      ... i need help extending the logic to have more activation blocks however between the flip-flops, ANDs, and NOTs I haven't for the life of me know how to get into the Boolean logic to do it. Unless there's another contraption on the dock that does this i need help making this longer.
      thanks for the help so far and i hope this doesn't confuse anyone.
       
    9. Captain Skwidz

      Joined:
      Jun 14, 2017
      Messages:
      53
      Hmm... I'll have to dissect the prototype. The rotation works and the counter seems to. I just don't know why it won't fire. Once I've done that I should have a solution (unless the wifi blocks really are broken in this current release or something is messed up in the gun).

      SachysSachys An OR gate at the start of the clock? Why? The AND gate is so that it can "turn off" the clock. I can probably see it causing issues in really complex builds on servers where your build is a fancy turing machine where a constantly active clock could lag.
       
    10. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      yeah there's an issue with the rotation and actual firing but i just ignore that stuff. i use the button under the 'not' block for a logic semi-auto gun with a 4-shot magazine.
       
    11. GalactusX

      Community Mentor

      Joined:
      Jul 30, 2013
      Messages:
      376
      Hi mate ... you want to build something similar to this?
      [​IMG]
       
    12. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      YES (well kinda)
      well all the output barrels i want to put in a line making just 1 barrel and want to use cannon+slaved beam weapon groups as the bullets are much faster.
       
    13. Sachys

      Sachys Hermit.

      Joined:
      Nov 30, 2015
      Messages:
      355
      As i said: an AND will AND. an OR is an on /off.
       
    14. GalactusX

      Community Mentor

      Joined:
      Jul 30, 2013
      Messages:
      376
      Only one final question ... How big do you want/needed it?
       
    15. Captain Skwidz

      Joined:
      Jun 14, 2017
      Messages:
      53
      I know what those do but how is an OR an on/off? It won't cut off the signal ending the clock unless some kind of bug is used because it is passive and doesn't act as a relay switch.
       
    16. Sachys

      Sachys Hermit.

      Joined:
      Nov 30, 2015
      Messages:
      355
      if you link the activation module to it / inner ship remote, it will become the on/off inthe or/not/delay loop. and can cause issues here sometimes. does that make more sense?
      not trying to be confusing, was late last night when i posted and havent had any coffee yet today.
       
      • Informative Informative x 1
    17. GalactusX

      Community Mentor

      Joined:
      Jul 30, 2013
      Messages:
      376
      Not sure ... but this is what you want to do?

      [​IMG]

      * the shots do not look good due to the filthy recording system of starmade gifs *
       
      #17 GalactusX, Dec 11, 2017 at 2:12 PM
      Last edited: Dec 11, 2017 at 2:25 PM
      • Like Like x 1
    18. Bushmaster6000

      Joined:
      Dec 12, 2014
      Messages:
      13
      Starmade_Fast-MG_proj.jpg
      nah just 1 barrel with outputs in a line cuz; 1) its simpler, 2) easier to make something look cool out of, and 3) bullets go so fast your OCD shouldn't notice it at all. i'm just looking for a way to extend sven's minigun logic to have 20+ outputs instead of just his original 4.

      p.s. just realized if you click the button only once it activates 2 of the activation modules because its a button which sends 2 pulses, should switch this out with just an activation module.
       
    19. Captain Skwidz

      Joined:
      Jun 14, 2017
      Messages:
      53
      Huh, buttons are weirder than I thought and I don't know exactly how the prototype logic works. Also it's a bit outdated (not a pun). The only other way I can think of that allows auto-rapid fire without using canon-canon slave is using rails with rail speed controller(s) and have a docked thing move back and forth activating buttons (or activation modules?) connected to each master computer. I'll give up testing my previous theory and try out the rail thing right now. If that doesn't work I'm at a loss.

      A mini-update: My crappy building failed miserably and I have to resort to binary counting and going back to dissect the prototype.
       
      #19 Captain Skwidz, Dec 11, 2017 at 7:39 PM
      Last edited: Dec 11, 2017 at 8:10 PM
    20. Sachys

      Sachys Hermit.

      Joined:
      Nov 30, 2015
      Messages:
      355
      you cant do auto rapid fire with cannon cannon slave - it will just fire one shot. you need to time it with a clock for continual autofire (in which case no secondary slave or beam / pulse would be preferable).
       
    Loading...