User Tag List

Results 1 to 5 of 5

Thread: Shooting an object at another object is wildly inaccurate

  1. #1
    Clicker Fusion 2.5 (Steam)

    Join Date
    May 2013
    Posts
    45
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Shooting an object at another object is wildly inaccurate

    Evening all,

    I have an active (Circle) which rotates and the action point is set to the outside of the circle
    I have another Active (target) which is fixed to the circles action point
    I then have an action that states "When left mouse is clicked stop rotation of circle and launch object in direction of target"

    problem is the "bullet" never passes through the target active and sometimes misses by as much as 32 pixels.

    I am sure I saw a shooting example as a lopop on here but i cant for the life of me find it anywhere.

    Any ideas or a link to the above example?

  2. #2
    Clickteam Clickteam
    Jeff's Avatar
    Join Date
    Jun 2006
    Location
    Battle Ground Washington
    Posts
    11,822
    Mentioned
    7 Post(s)
    Tagged
    2 Thread(s)
    There are a lot of 360 degree shooting examples but I would also love to see an example file of what your doing to see if we can make the built in shooting better.

    Check this site for the examples.
    http://www.castles-of-britain.com/mmf2examples.htm

  3. #3
    Clicker Multimedia Fusion 2 DeveloperiOS Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)
    King_Cool's Avatar
    Join Date
    Aug 2008
    Posts
    2,335
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can get this kindog inaccuracy when using some of the built in movements, since many of them use 32 directions only.

    For more a more accurate/ smooth result you should do 2 things.

    USE FLOAT X Y COORDINATES
    The built in coordinate system is int based, meaning an Object cant have a X or Y coordinate of, say, 5,5 or 8,33 ( if you try it will 'round' the coordinate ).
    This is in many cases a problem if you want to apply more smooth movements to Objects.
    AlterableValues can hold Float values ( decimal numbers ), so to use Float coordinates give your bullet 2 AltValues called X_ and Y_.

    USE 360 DEGREES OF MOVEMENT
    Many of the built in movements are limited to a maximum og 32 directions of movement, wich as you have experienced can be quite inaccurate for longer travel distances.
    To give your bullet 360 degrees of directional movement as opposed to only 32 directions, give your bullet an AltValue called Angle_

    MOVE
    To now make your bullet move in a direction at a speed, do this code:

    + Allways
    -> bullet set X_ to X_ - Sin( Angle_ ) * speed
    -> bullet set Y_ to Y_ + Cos( Angle_ ) * speed

  4. #4
    Clicker Fusion 2.5Fusion 2.5 MaciOS Export ModuleInstall Creator Pro
    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)
    advaith's Avatar
    Join Date
    Jun 2015
    Location
    SF Bay Area, California, USA
    Posts
    1,325
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Jeff View Post
    ...but I would also love to see an example file of what your doing to see if we can make the built in shooting better.
    I have an example of this, click here, click Mercury, and try to shoot all the aliens without moving, especially the middle row.

  5. #5
    No Products Registered

    Join Date
    Apr 2017
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    try to use clickteam movement controller

Similar Threads

  1. 360 Shooting with PMO Object and animation?
    By darkmanx_429 in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 5th January 2013, 09:06 PM
  2. CRC32 Object Inaccurate
    By Kracker in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 27th May 2011, 09:20 AM
  3. [BUG] Shooting an object and deleting it
    By RickyRombo in forum Multimedia Fusion 2 - Technical Support
    Replies: 0
    Last Post: 11th April 2010, 01:52 AM
  4. Shooting direction inaccurate
    By PengeyPenguin in forum The Games Factory 2 - Technical Support
    Replies: 15
    Last Post: 9th August 2009, 09:40 PM
  5. Shooting An Object
    By JonesGJ in forum The Games Factory 2 - Technical Support
    Replies: 4
    Last Post: 13th November 2006, 09:26 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
  •