RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
[GM] Having a character attack the other

0 Members and 1 Guest are viewing this topic.

*****
Ancient Mummy
Rep:
Level 90
this forum is so dead...
( atleast this section is.)

But I need help!

When I have my character press A to go ZWASHAM SLASSH!!!

How do I make sure it acctually hits the target?

Can anyone help me?
« Last Edit: January 04, 2012, 10:55:11 PM by modern algebra »


********
Hungry
Rep:
Level 96
Mawbeast
2013 Best ArtistParticipant - GIAW 11Secret Santa 2013 ParticipantFor the great victory in the Breakfast War.2012 Best Game Creator (Non-RM Programs)~Bronze - GIAW 9Project of the Month winner for December 2009Project of the Month winner for August 20082011 Best Game Creator (Non RM)Gold - GIAW Halloween
create a collision inside the character sprite and on swing have a collision check to see if you hit.

FCF3a A+ C- D H- M P+ R T W- Z- Sf RLCT a cmn+++ d++ e++ f h+++ iw+++ j+ p sf+
Follow my project: MBlok | Find me on: Bandcamp | Twitter | Patreon

*****
Ancient Mummy
Rep:
Level 90
I now created it so that when I press A my character changes into a different object which will kill the object on colliding.
It looks a bit weird but it works for now, I created a different object for left and right and its quite allot of work. I think their should be an way easier way though.

Anyways thanks, It works for now :p

********
Hungry
Rep:
Level 96
Mawbeast
2013 Best ArtistParticipant - GIAW 11Secret Santa 2013 ParticipantFor the great victory in the Breakfast War.2012 Best Game Creator (Non-RM Programs)~Bronze - GIAW 9Project of the Month winner for December 2009Project of the Month winner for August 20082011 Best Game Creator (Non RM)Gold - GIAW Halloween
idk if I explained it correct or not but...blah

haha, glad it's working I guess

FCF3a A+ C- D H- M P+ R T W- Z- Sf RLCT a cmn+++ d++ e++ f h+++ iw+++ j+ p sf+
Follow my project: MBlok | Find me on: Bandcamp | Twitter | Patreon

********
Rep:
Level 96
2011 Most Missed Member2010 Zero To Hero
Better idea: The character and the sword are separate sprites. When you swing, create an object using the sword sprite in line with the character sprite. That way, it will kill on collision with the blade, but not the character.

**
Rep: +0/-0Level 84
Onward to failure! March you heathens, MARCH!
Hm, I happen to be a somewhat expirienced with GML, so I might be able to help if you have problems. Because Game Maker has a wide range of variety in the games it could make, (Heck, if I wanted to, I could make an RPG engine if I tried!) it's always a good idea to post screenshots and be really descriptive with your issue. Posting an example exe. also makes a world of good to the people helping you.

~Darkblast
« Last Edit: July 28, 2009, 04:40:35 AM by darkblast »
The biggest mistake of RMRK since 2009...
~Darkblast