1. First install Grimrock Model Toolkit and download the Asset Pack.
2. Open GMT and the dungeon_secret_door.model
3. Go to Model Nodes: Node 2 :Gates
4. Changes the 0,01 in Matrix to 0
5. Save your file as : invisible_wall.model in your mod_assets/models folder
6. In objects.lua:
SpoilerShow
Code: Select all
cloneObject{
name = "invisible_wall",
baseObject = "dungeon_secret_door",
model = "mod_assets/models/invisible_wall.fbx",
}
Open the editor and place the dungeon_catacomb_empty and your invisible_wall at the same place
Now you have a dungeon catacomb (or what you want) secret door.
But to open the secret door you must through script.
Connect a wall_button to a function script_entity.
1.The simplest
- connect the wall button to your invisible_wall : open
- connect the wall button to this function
SpoilerShow
Code: Select all
function wallsecret()
dungeon_catacomb_empty:destroy()
end
And you probably need to add a counter because the function can not destroy execute if the object does not exist (if you press the button repeatedly).
So:
2. A little more difficult
- set a counter
- connect the wall button to this function:
SpoilerShow
Code: Select all
function wallesecret()
if counter:getValue() == 0 then
dungeon_catacomb_empty:destroy()
invisible_wall:destroy()
spawn("dungeon_secret_door", L, X, Y, facing,"secret_door_catacomb")
secret_door_catacomb:open()
counter:setValue(1)
end
end
Now you have a custom secret wall with the sound and the animation. You can put monster in your secret place, they can't come if the invisible_wall is not open or destroy.
It's not perfect but better than nothing. If you have any suggestions and improvements: Thanks.