CMP #$01
BEQ continueShooting
LDA #$00
STA preventShooting
LDX player1_object
LDA Object_movement,x
AND #%00000111
ORA #%00000010
STA temp3
CMP #%000000010
BNE notRightForProjShoot
LDA Object_x_hi,x
CLC
ADC #$18
STA temp
JMP gotDirForShoot
notRightForProjShoot:
LDA Object_x_hi,x
;;; offset x for creation
CLC
ADC #$01 ;;<<-- horizontal offset of your weapon from your player/monster (change the value to adjust)
STA temp
gotDirForShoot:
LDA temp3
TAY
LDA DirectionMovementTable,y
ORA temp3
STA temp3
LDA Object_y_hi,x
CLC
ADC #$08 ;; height pixels lower
STA temp1
LDA preventShooting
BNE +
ChangeObjectState #$03, #$08
CreateObject temp,temp1,#$01, #$00
LDA temp3
STA Object_movement,x
LDA #$01
STA preventShooting
+
RTS
DanielT1985 said:I've gotten my character to shoot the projectile, but like what other people were having a problem with, they can't fix the position of where it throws. And for me, I can't seem to kill enemies with my weapon, even though I set the enemy to be killed via the projectile itself. And also, when I try walking, and then hold the B button to run, my character is stuck in its idle animation. So is there a way to make the player shoot the projectile without changing the player's animations?
dale_coop said:And to give your player the weapons, from the beginning, just check in the Project > Infos,to have them by default (cf the adventure tutorial).
Can I ask you... did you watch the tutorial videos?
dale_coop said:And to give your player the weapons, from the beginning, just check in the Project > Infos,to have them by default (cf the adventure tutorial).
Can I ask you... did you watch the tutorial videos?
DanielT1985 said:dale_coop said:And to give your player the weapons, from the beginning, just check in the Project > Infos,to have them by default (cf the adventure tutorial).
Can I ask you... did you watch the tutorial videos?
Okay, so one thing I now know is that Monster Weapon, which is what I had it set to, will not let you kill the enemy with the Projectile. So having it set to just Monster and not turning on Jump On Kills will make it so you need the projectile to kill the enemy. Now all I need to learn is positioning the projectile.
Might be your mistake, your player's projectile object needs to be a "Player Weapon" ("Player Weapon" type objects will hurt monsters, as "Monster weapon" ones will hurt the player).So one thing I now know is that Monster Weapon, which is what I had it set to, will not let you kill the enemy with the Projectile
When you set the "Jump On Kills" flag for your monsters, it just means your monster will be killed if the player jumps on it (like in super mario bros).So having it set to just Monster and not turning on Jump On Kills will make it so you need the projectile to kill the enemy
When you kill a monster, it gives you a "Health object" or a "Currency object" or nothing. And it will create a "Effect 1" object (for example, in the tutorial, a pow! when it dies).Another thing weird is that the enemy will both turn into my health pickup AND produce a fireball. IDK what to do with that.
dale_coop said:Might be your mistake, your player's projectile object needs to be a "Player Weapon" ("Player Weapon" type objects will hurt monsters, as "Monster weapon" ones will hurt the player).So one thing I now know is that Monster Weapon, which is what I had it set to, will not let you kill the enemy with the Projectile
When you set the "Jump On Kills" flag for your monsters, it just means your monster will be killed if the player jumps on it (like in super mario bros).So having it set to just Monster and not turning on Jump On Kills will make it so you need the projectile to kill the enemy
When you kill a monster, it gives you a "Health object" or a "Currency object" or nothing. And it will create a "Effect 1" object (for example, in the tutorial, a pow! when it dies).Another thing weird is that the enemy will both turn into my health pickup AND produce a fireball. IDK what to do with that.
Currenlty, in your project, it seems you haven't configured yet those objects ("Health object", "Currency object" and "Effect 1").
Note: the head (the first tile of your tileset) is the empty tile. When not configured and object is just an empty tile.
dale_coop said:You could comment the related (« createobject ») lines in the handlemonsterdrops.asm script