[4.1] Magic Projectile Goes Through Enemies

dale_coop

Moderator
Staff member
Don't worry, I am glad to help you. It's normal, as Joe helped me and jorotroid and chronosv2 and CutterCross... with all their scripts, ideas and advices.
If I can, if I have time, no problem. And it will help some nesmakers in the same situation than you was/are.
 

nroflmao

New member
OK so i think i implemented all the script updates as you suggest and seems to be working now, only thing that doesn't work is the player ouch sound when gets hit by a monster. It looks like i should be using the SND_HURT_PLAYER to do it, as my HandlePlayerHurt script shows:

Line
Code:
	LDA Object_health,x
	SEC
	SBC #$01 ;; subtract other's strength
	CMP #$01
	BCS notPlayerDeath
	
	PlaySound #SND_HURT_PLAYER
	JSR HandlePlayerDeath
	JMP doneWithPlayerHurt

but when i use the Sound/SFX to map a sound to a new constant SND_HURT_PLAYER it does nothing...i wonder if this is already defined somewhere else and being overwritten?
 

nroflmao

New member
I can get the player hurt sound to work if i add it to the HandleObjectCollisions.asm around line 230


Code:
notLethalInvincible:
	
	;;;;;;;;;;;;;;;;;
	;;;;;;;;; WHAT HAPPENS WHEN PLAYER IS HURT
	.include SCR_PLAYER_HURT_SCRIPT
	;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
	;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
	PlaySound #SND_HURT_PLAYER ;; NR add to see if it works
	
playerWasHurtDuringCollision:

not sure why its not working though without having to add this code.
 

MistSonata

Moderator
I know this is late, but did you check to make sure that the projectile's "Solid Object Reaction" is set to "Destroy Me"?
 
Top Bottom