I was trying out the code to make a full screen scroll, and this works fine:
Code: Select all
function render_large_scroll(self, id, whose_eye)
if (exvar[id] and exvar[id].textID) then
scroll_ID = exvar[id].textID
dsb_fullscreen(show_large_scroll_and_text, EXIT_ON_CLICK, nil, true, false)
end
end
scroll_strings = {
[1] = "Scroll 1 Text",
[2] = "Scroll 2 Text",
[3] = "Scroll 3 Text"
}
obj.scroll_large = clone_arch(obj.scroll, {
name="LARGE SCROLL"
on_look=render_large_scroll
})
function show_large_scroll_and_text(bmp)
dsb_bitmap_textout(bmp, gfx.font_colortest, string.upper(scroll_strings[scroll_ID]), 320, 240, CENTER, colour_white)
end
Code: Select all
function obj.scroll_large:on_look(self, id, whose_eye)
scroll_ID = exvar[self].textID
dsb_fullscreen(show_large_scroll_and_text, EXIT_ON_CLICK, nil, true, false)
end
scroll_strings = {
[1] = "Scroll 1 Text",
[2] = "Scroll 2 Text",
[3] = "Scroll 3 Text"
}
obj.scroll_large = clone_arch(obj.scroll, {
name="LARGE SCROLL"
})
function show_large_scroll_and_text(bmp)
dsb_bitmap_textout(bmp, gfx.font_colortest, string.upper(scroll_strings[scroll_ID]), 320, 240, CENTER, colour_white)
end