User Tag List

Results 1 to 5 of 5

Thread: Need Help with Player Damage

  1. #1
    No Products Registered

    Join Date
    Oct 2010
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Need Help with Player Damage

    I am currently working on a game and I want to make the game make the player's health slowly go down when they step on a hazard until they step off of it.
    Example: My player's health is represented in a Counter. I want to make it to where when they step on a fireball and the counter goes down by 5 every second or so until they step off of it. How can I program it to do so?

  2. #2
    Clicker Multimedia Fusion 2 Developer

    Join Date
    Jun 2006
    Location
    Darlington, UK
    Posts
    3,298
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Need Help with Player Damage

    Every 1 second
    +player is overlapping fireball
    -subtract 5 from counter

    ?

  3. #3
    Clicker

    Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform 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)Universal Windows Platform Export Module (Steam)
    DaveC's Avatar
    Join Date
    Jun 2007
    Location
    Perth, Australia
    Posts
    2,132
    Mentioned
    16 Post(s)
    Tagged
    0 Thread(s)

    Re: Need Help with Player Damage

    it would be more reliable if you did it like this.

    +Player is overlapping Fire
    - Add 1 to Value X

    +Value X = 30
    - Subtract 1 from Health
    - Set Value X to 0

    what this does is it always adds 1 to value X (a kind of damage timer) while the player is overlapping the fire. When the value X reaches a certain limit (in this example 30) the damage is done to the player and the timer value is reset.

  4. #4
    Clicker Multimedia Fusion 2 DeveloperiOS Export ModuleSWF Export Module
    Jaffob's Avatar
    Join Date
    May 2008
    Location
    USA
    Posts
    1,833
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Need Help with Player Damage

    +Player is overlapping Fireball
    +Restrict actions for 1 second:
    ===Subtract 5 from counter

    That's the best way.

  5. #5
    Clicker Multimedia Fusion 2 Developer

    Join Date
    Jun 2006
    Location
    Darlington, UK
    Posts
    3,298
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Need Help with Player Damage

    Jaffob is right, that's much better than using "every".

Similar Threads

  1. RPG-like damage counters
    By camelman in forum Multimedia Fusion 2 - Technical Support
    Replies: 14
    Last Post: 18th April 2013, 07:33 PM
  2. Battle damage
    By Twario in forum The Games Factory 2 - Technical Support
    Replies: 4
    Last Post: 5th July 2010, 06:36 AM
  3. Enemys take damage.
    By Dakk in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 22nd March 2010, 11:09 AM
  4. Damage and Miss above player (RPG style)
    By Bernardo3D in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 9th October 2009, 09:41 PM
  5. RPG Damage Formula
    By ZayLong in forum Multimedia Fusion 2 - Technical Support
    Replies: 11
    Last Post: 5th September 2008, 08:14 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
  •