Legend of Grimrock
Create and download new dungeons, items, monsters, & environments
Use the Dungeon Editor to build entirely new adventures and challenges for other players to solve. Fill your dungeons with puzzles, traps, or even totally new items, monsters and environments with custom graphics and audio! Click here to learn more.
SirArthurIV Nov 28, 2012 @ 1:26pm
Scrolls with Text in Items
I want to put a scroll with text on it on an altar. How would I go about doing that?
Showing 1-2 of 2 comments
< >
LD-SK 2 Feb 11, 2013 @ 1:08am 
OK, complete walkthrough:

find entity "script" (in "Logic" list).
click on it, then add it anywhere into your map.

then switch to edit mode ("arrow symbol" top-left), click on the script entity (it shows as "lua" in the grid).

Once you do, you will see a large gray space in its properties -- this is room for writing a script.

write in the following (you can copy this in safely):
local message = spawn("scroll") -- don't change anything here.
message:setScrollText("This is my fancy scroll text. \n this will show on second row \n this on third row") -- of course you will want to edit the text in quotation marks.
-- The following are SOME options where you can add your scroll. ONLY use one of these!
-- Option 1:
myAlcove:addItem(message) -- this will move the created scroll INTO the alcove.
-- or:
-- Option 2:
myAltar:addItem(message) -- the same works for altars, too.
-- or:
-- Option 3:
mySack:addItem(message) -- or if you want to put the scroll into a SACK.

Of course, this code will only work if you have an ALCOVE, an ALTAR or a SACK with the proper id (= add one of those objects to the map, then click on it with the edit tool, and change its ID to myAlcove, myAltar or mySack, respectively).

Since the code is NOT in any function, it will get executed immediately when the map is loaded.

Let me know if this helped.
LD-SK 2 Feb 11, 2013 @ 1:11am 
just a remark: Sometimes instead of a scroll, you may want a Note (torn piece of paper). then, you just change
local message = spawn("scroll")
local message = spawn("note")

Everything else stays the same.
Showing 1-2 of 2 comments
< >
Per page: 15 30 50