User Tag List

Results 1 to 8 of 8

Thread: Different characters with unique acceleration-How?

  1. #1
    No Products Registered

    Join Date
    Nov 2006
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Different characters with unique acceleration-How?

    I'd like to have different acceleration for different characters. What would be a good way of doing this? Currently, I have the different accelerations stored in AVs on each character, which are sent to another object depending on if that character is Player1 or Player2, and then that value is used in events. Right now, if I hold down the right key, for instance, a value is added to (let's call this value, accel). Once accel reaches the acceleration number, 1 is added to the horizontal movement, and accel is set to 0. I don't think this method works very well, though, because it doesn't provide a very gradient (I think that's a pretty good word choice) acceleration customization. In other words, an accleration of 2 is very different compared to an acceleration of 3. Could someone help me find a better way of doing this?

    Thanks,

    Neonotso

  2. #2
    Clicker Multimedia Fusion 2

    Join Date
    Jun 2006
    Location
    Montreal, Canada
    Posts
    234
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-How?

    You could store object's X-Y positions as float AVs and also use float values for your acceleration calculations. And then convert them back into pixel positions afterwards, where you're ready to really move the objects.

  3. #3
    No Products Registered

    Join Date
    Nov 2006
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-

    Thanks! Although, what's a float value? I've heard of it, but I'm not sure what it's used for. I'm going to check around the forum and see if I can find some info, but if someone posts here before I find something then that's okay, too.

  4. #4
    No Products Registered

    Join Date
    Jul 2006
    Location
    Umeå, Sweden
    Posts
    1,090
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-

    Float values are values that use decimals (ie. 3.1415)
    The values that don't use decimals are called Integers

  5. #5
    No Products Registered

    Join Date
    Nov 2006
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-

    Okay, thanks! I didn't know you could use decimals (or floats) for AVs. I wasn't sure, anyway. I think that would definitely help.

  6. #6
    No Products Registered

    Join Date
    Nov 2006
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-

    Hmm... this isn't working so well. I'm using an INI now. It has the value 2.2 stored on it, which I can see from the debugger. When I set my AV or even a counter to it, though, it becomes 2. Just now, I tried making this event:

    Value(INI) = 2.2
    - Set counter to Value(INI)

    It didn't work, but when I said...

    Value(INI) <> 2.2
    - Set counter to Value(INI)

    ...it worked, but the counter was set to 2. Does anyone know a way to fix or get around this problem, or should I not be using an INI to store the data?

    Thanks for your help,

    Neonotso

  7. #7
    Clicker Multimedia Fusion 2

    Join Date
    Jun 2006
    Location
    Montreal, Canada
    Posts
    234
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-

    I have really no idea if the functions of the INI object can return a float value.
    Just to be safe, you should store your value as (2.2 * 100) and get it back later as (Value(INI) * 0.01)
    It will be 220 in the ini file, but still read as 2.2 by your application.

  8. #8
    No Products Registered

    Join Date
    Nov 2006
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Different characters with unique acceleration-

    Oh yeah, I read that in a different thread, but I forgot to try it. I'm going to try it, thanks!

    EDIT: Woo-hoo!! It works! Thanks everyone!

Similar Threads

  1. Unique Timers
    By wizaerd in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 16th September 2013, 02:39 PM
  2. Unique alterable value for each of the same object
    By Oreo in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 11th June 2010, 09:49 PM
  3. [Possible Bug] Unique ID not working
    By LB in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 30th January 2010, 01:05 PM
  4. ICpro - Serial unique ?
    By K666 in forum Install Creator and Patch Maker
    Replies: 25
    Last Post: 1st August 2008, 09:34 AM
  5. Unique PC Identifier
    By Steven in forum Multimedia Fusion 2 - Technical Support
    Replies: 11
    Last Post: 19th March 2008, 08:17 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
  •