User Tag List

Results 1 to 7 of 7

Thread: Shooting multiple bullets in cone?

  1. #1
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Unknowner's Avatar
    Join Date
    Oct 2011
    Posts
    92
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Shooting multiple bullets in cone?

    Hi, im trying to make a shotgun effect, tryed this formula saw here on forums >>> (OAngle("pellet",X of crosshair, Y of crosshair) + RRandom(-30,30) ) / 11.25 but aint working at all, sometimes shoots 1-2-3 bullets even i put them on a fastloop, anyone knows why aint working?

  2. #2
    Clicker Fusion 2.5 DeveloperiOS Export ModuleSWF Export Module
    Sumo's Avatar
    Join Date
    Jul 2008
    Posts
    642
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Shooting multiple bullets in cone?

    What's the problem exactly? What kind of system are you using for shooting? Using sin and cos to move the bullets with 360 degree shooting?

    The formula you posted:

    Oangle will find the difference in angle between the bullet and crosshair and have it pointed in that direction. Then random will give it the random spread +\- 30 degrees. The dividing by 11.25 converts the 360 degrees to 32 directions. So if you're not using launch bullet towards direction with the 32 directions, it probably won't work.

    Use a sin and cos bullet movement and just add the random angle to the bullet before it's shot.


    Sent from my iPhone using Tapatalk

  3. #3
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Unknowner's Avatar
    Join Date
    Oct 2011
    Posts
    92
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Sumo View Post
    What's the problem exactly? What kind of system are you using for shooting? Using sin and cos to move the bullets with 360 degree shooting?

    The formula you posted:

    Oangle will find the difference in angle between the bullet and crosshair and have it pointed in that direction. Then random will give it the random spread +\- 30 degrees. The dividing by 11.25 converts the 360 degrees to 32 directions. So if you're not using launch bullet towards direction with the 32 directions, it probably won't work.

    Use a sin and cos bullet movement and just add the random angle to the bullet before it's shot.


    Sent from my iPhone using Tapatalk
    I was trying to shot a cone of 3 bullet in direction of my crosshair at 360 degrees, can u give me an example please? i can't get the sin and cos work

  4. #4
    Clicker Fusion 2.5 DeveloperiOS Export ModuleSWF Export Module
    Sumo's Avatar
    Join Date
    Jul 2008
    Posts
    642
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Here's a quick example for you.
    Attached files Attached files

  5. #5
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Unknowner's Avatar
    Join Date
    Oct 2011
    Posts
    92
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Sumo View Post
    Here's a quick example for you.
    thanks, that's what I wanted to do but with less randomize, will try to figure how

  6. #6
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Unknowner's Avatar
    Join Date
    Oct 2011
    Posts
    92
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Unknowner View Post
    thanks, that's what I wanted to do but with less randomize, will try to figure how
    Well I was testing and I want to shot the bullets on a Angle( "player" ) + -15, 0 and 15 instead of RRandom( - 15, 15 ), is there a way to make it in the same function? i tryed increasing an alterable value to +15 and surplus that but aint working at all since it shot all at the same time
    Also I did it with 3 functions calling each other with modifyed angle but seems like it can be done in one function instead of 3

  7. #7
    Clicker Fusion 2.5 DeveloperiOS Export ModuleSWF Export Module
    Sumo's Avatar
    Join Date
    Jul 2008
    Posts
    642
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Shooting multiple bullets in cone?

    Instead of random, set the bullet angle to current angle-15. Then copy and paste all the actions for a second bullet and edit the angle to current angle. Then copy it again and set it to current angle+15. Then set the loop number to 1 since you're creating 3 bullets in 1 loop.

    Or instead, copy the bullet creation loop code 2 more times and compare the loop index to 0, 1, and 2 (loops start with a 0 index). Then for each one edit the bullet angle. Then edit the number of times the loop runs for and change it to 1.

    Or set the angle to current angle+alterable value. And add another line on the loop before the bullet creation loop to change that alterable value to -15, 0, or 15, but you would have to compare to the loop index beforehand as well.


    Sent from my iPhone using Tapatalk

Similar Threads

  1. Replies: 9
    Last Post: 23rd May 2015, 01:08 AM
  2. Shooting Bullets Fast Loop problem
    By N64Mario in forum Multimedia Fusion 2 - Technical Support
    Replies: 6
    Last Post: 19th September 2009, 09:51 PM
  3. Bullets not shooting from action point
    By dub in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 29th March 2008, 02:11 PM
  4. Multiple Turret Shooting With Multiple Targets
    By Brandon in forum File Archive
    Replies: 4
    Last Post: 29th January 2008, 03:34 AM
  5. Problems with multiple objects shooting
    By krick in forum Multimedia Fusion 2 - Technical Support
    Replies: 6
    Last Post: 1st August 2006, 04:37 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •