The "Monster Block" type tiles [NESMaker 4.0.6]

dale_coop

Moderator
Staff member
For those who want tiles that can be walkable by the player, blocked for monsters, here the script for "Monster Block" tile type (from the beta)...

Make a "MonsterBlock.asm" script in your "Routines\UserScripts\BasicScripts\TileScripts" folder, with:
Code:
;; MONSTER BLOCK	
	;;; skip monster block if player
	LDA Object_flags,x
	AND #%00001000 ;; is it a monster?  
	BEQ skipMonsterBlock;; skip monster block if not a monster
	;; do any other checks here.  Is there a bit you want to use to determine
	;;; whether or not specific monsters ignore monster blocks?  like flying monsters, etc?
	LDA #TILE_SOLID
	STA tile_solidity
skipMonsterBlock:
  RTS

Then in "Project Settings > Project Labels", rename for exemple the unused Tile Types "Tile 08" to "Monster Block", then in "Project Settings > Scripts Settings" assign the "MonsterBlock.asm" script to "Tile Collision 08".

VoilĂ , now you can make Monster Block type tiles!
 
Top Bottom