Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

 
Advanced search

878483 Posts in 32924 Topics- by 24336 Members - Latest Member: BeefJack

May 22, 2013, 01:42:48 AM
TIGSource ForumsDeveloperTechnical (Moderators: Glaiel-Gamer, ThemsAllTook)Melee attack game maker
Pages: [1]
Print
Author Topic: Melee attack game maker  (Read 137 times)
Reggie02
Level 0
**


View Profile
« on: May 19, 2013, 03:02:30 PM »

Hi guys. I started game maker a while ago and I'm making a platform engine. everything is fine so far apart from melee attacks and climbing edges/ledges but For now, I would like to know how I can implement melee attacks. What I have in mind is changing the sprite when a button is pressed and if player collides with enemy while in attack sprite, take health from enemy but there are obviously many issues with that. Any help is appreciated and code + explaination will be very appreciated  Smiley
Logged
mokesmoe
Level 10
*****



View Profile Email
« Reply #1 on: May 19, 2013, 04:11:31 PM »

You will want to make a separate object for the attack's hitbox, and make the player's hitbox not include the weapon (or limb). If an enemy touches the attack object it gets hit.
Logged
Geeze
Level 5
*****


Totally.


View Profile
« Reply #2 on: May 20, 2013, 05:58:40 AM »

Or you could make melee attacks projectiles (engine-vice) that disappear really fast.
Logged

Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic