Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
hyperPad

hyperPad Forum

  1. Home
  2. General Discussion
  3. Weapon Shooting issue

Weapon Shooting issue

Scheduled Pinned Locked Moved General Discussion
6 Posts 3 Posters 1.2k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Coco cashewA Offline
    Coco cashewA Offline
    Coco cashew
    wrote on last edited by
    #1

    Greetings all, new here

    My issue, weapon continuously fires when the value of bullets is at 0.

    Would it be best to turn off “shooting button” behavior.
    Or instead Leave shooting button on, and base shooting options on the value of bullets acquired.

    Input appreciated.
    Cheers.

    Aidan_FireA 1 Reply Last reply
    0
    • Coco cashewA Coco cashew

      Greetings all, new here

      My issue, weapon continuously fires when the value of bullets is at 0.

      Would it be best to turn off “shooting button” behavior.
      Or instead Leave shooting button on, and base shooting options on the value of bullets acquired.

      Input appreciated.
      Cheers.

      Aidan_FireA Offline
      Aidan_FireA Offline
      Aidan_Fire
      wrote on last edited by
      #2

      @Aero It depends on the kind of setup you're trying to make. The number of bullets field in the shoot behaviour I think just means how many bullets can exist at one time.

      1 Reply Last reply
      0
      • Coco cashewA Offline
        Coco cashewA Offline
        Coco cashew
        wrote on last edited by Aero
        #3

        My gun button is kinda like this.
        How wrong or right is this? Both sets linked to gun

        Behavior one
        A. Shoot with button
        B. Subtract Value -1
        C. Add to score

        Behavior two
        A. Get value
        B. If value 1>0
        C. Shoot with button ( behavior on)
        D. if value 0=0
        E. Shoot with button ( behavior off)

        The goal is to disable shooting when there is no rounds left.

        MelideM 1 Reply Last reply
        0
        • Coco cashewA Coco cashew

          My gun button is kinda like this.
          How wrong or right is this? Both sets linked to gun

          Behavior one
          A. Shoot with button
          B. Subtract Value -1
          C. Add to score

          Behavior two
          A. Get value
          B. If value 1>0
          C. Shoot with button ( behavior on)
          D. if value 0=0
          E. Shoot with button ( behavior off)

          The goal is to disable shooting when there is no rounds left.

          MelideM Offline
          MelideM Offline
          Melide
          wrote on last edited by
          #4

          @Aero You can be creative on that. Also using an array could work: Creating for example 6 value in the array> When you shoot, it removes one value of the array and check how many values left in the array with the " Get Array Count " behavior, if the " Get Array Count " become 0 then it'll directly turn off the " Shoot with button " and turn on another behavior that is " Start Touching ". While you " Start Touching ", it will directly turn off the " Start Touching " behavior and read what is next wich is adding 6 value in the array and waiting maybe 0.4 second before turning on the " Shoot with button " and you could also put an audio of a reloading weapon to shows that the weapon is reloaded.

          1 Reply Last reply
          0
          • Aidan_FireA Offline
            Aidan_FireA Offline
            Aidan_Fire
            wrote on last edited by
            #5

            There are many ways you can do it. Personally, this is how mine would work (assuming the gun is automatic):
            9B194984-B541-4C17-9589-BFD2AEB2A6CC.png
            In case you don't know how to produce that Set Input Field behaviour:
            F29E6B2B-04CF-46D0-8A5D-16E651A25608.jpeg

            1 Reply Last reply
            1
            • Coco cashewA Offline
              Coco cashewA Offline
              Coco cashew
              wrote on last edited by
              #6

              @Aidan-Oxley Thank you that is a helpful outlook.

              1 Reply Last reply
              0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Search