Basic Melee Weapon Issues

Having trouble compiling code? Getting an unexpected error? Player not appearing on screen? Seeking answers on how to do a particular thing? This is the forum you're looking for, to ask other NESmaker users for assistance.
User avatar
stevenshepherd
Posts: 236
Joined: Sun Feb 18, 2018 5:25 pm

Re: Basic Melee Weapon Issues

Post by stevenshepherd » Sun Jan 13, 2019 3:34 am

I figured out how to do a makeshift animated object melee weapon by just using the projectile and setting its movement speed to very low and to destroy itself when the animation is over :) In the end I don't think I'll need it but it is fun to play around with what is available without getting into code (not that I am averse to getting into code, just not quite there yet).
User avatar
nroflmao
Posts: 40
Joined: Mon Aug 13, 2018 3:07 am
Location: Detroit, MI

Re: Basic Melee Weapon Issues

Post by nroflmao » Thu Jan 17, 2019 12:53 am

So I'm going to attempt to follow the conversion to melee object per Dale's instruction here, but before I do just wanted to try using this method and i am able to get an 8x8 sprite by changing the values of the user constants as described, but i wonder how would you change the palette that is used, looks like it uses Sub2 by default, i want it to use Sub1.
User avatar
nroflmao
Posts: 40
Joined: Mon Aug 13, 2018 3:07 am
Location: Detroit, MI

Re: Basic Melee Weapon Issues

Post by nroflmao » Sat Jan 19, 2019 4:51 pm

So I did give this a shot and it worked as advertised! I couldn't figure out how to do the vertical code so i just made a 16x16 sprite that can contain 8x16 and 16x8 (horizontal and vertical).

The only problem I have is if i slash the sword while walking the sword object doesn't move with the player object and thus it looks like the player is walking into the sword. The only way to avoid this is to make the sword animation extremely fast (1-2 frames, fast animation) just to minimize the effect.

I went back and checked 4.0.11 where i did the exact same thing and didn't have the issue. I notice in that version that my player stops movement while my sword animation plays and then continues once the animation is finished. Any ideas how i might implement the same behavior from 4.0.11?
User avatar
nroflmao
Posts: 40
Joined: Mon Aug 13, 2018 3:07 am
Location: Detroit, MI

Re: Basic Melee Weapon Issues

Post by nroflmao » Sat Jan 19, 2019 5:25 pm

OK so I found my issue...it seems somewhere along the line i have my input scripts set up to use the Base Input scripts rather than the adventure ones. Once I switch to the ones specifically for Adventure module, the player stops moving when attacking. Thanks again for the help Dale!
User avatar
dale_coop
Posts: 5215
Joined: Fri Feb 16, 2018 7:05 am
Location: France

Re: Basic Melee Weapon Issues

Post by dale_coop » Sat Jan 19, 2019 9:40 pm

We are still learning guys, still searching how to customize, fix some stufs.
Even myself I changed my Weapon game object tutorial ru use the end of action instead of end of animations, and I modified the StartMovingPlayerXxx.asm movement scripts.

To be more like it was in the 4.0

There can be still some issues, we are all trying to find solutions and tweak them.
-----
Sorry about my poor english
All I need: A Damn Fine Cup of Coffee
My games: PRESS START GAME / UNDERGROUND ADVENTURE / UNDERGROUND ADVENTURE (Arcade version - Byte-Off-2019)
My son's game: KUBO 3
Joshua Mason
Posts: 7
Joined: Mon Mar 25, 2019 9:56 am

Re: Basic Melee Weapon Issues

Post by Joshua Mason » Tue Apr 02, 2019 9:10 am

Quick melee question. I have my melee object appearing when I press the B button. Im in adventure module and set the constants to the correct sprite. they're one frame animations - basically a poke. Ive tried playing around with the settings, destroy after animation, etc, but the weapon doesnt disappear after it appears. It just sits there, and the main character cant move anywhere, but can face any direction with the appropriate facing melee. How can i get the weapon to disappear and get the character moving again? What should my action, end action and end animation be?
User avatar
dale_coop
Posts: 5215
Joined: Fri Feb 16, 2018 7:05 am
Location: France

Re: Basic Melee Weapon Issues

Post by dale_coop » Tue Apr 02, 2019 1:51 pm

Check your Player 's action step 3 : the "End of animation" needs to be set to "goToFirst" and don't forget to set an animation speed (or you could use "End of action" to "GotoFirst" and use a Timer value instead) .
-----
Sorry about my poor english
All I need: A Damn Fine Cup of Coffee
My games: PRESS START GAME / UNDERGROUND ADVENTURE / UNDERGROUND ADVENTURE (Arcade version - Byte-Off-2019)
My son's game: KUBO 3
Post Reply