Re: anything other than a wall to prevent player throwing st
Posted: Mon Nov 26, 2012 6:45 pm
For scroll images, you can do it case by case like so:
in items.lua:
in the script in the dungeon:
in items.lua:
Code: Select all
defineObject{
name = "note_map1",
class = "Item",
uiName = "Note",
model = "assets/models/items/note.fbx",
gfxIndex = 114,
scroll = true,
weight = 0.1,
}
defineObject{
name = "note_map2",
class = "Item",
uiName = "Note",
model = "assets/models/items/note.fbx",
gfxIndex = 114,
scroll = true,
weight = 0.1,
}Code: Select all
if wasHoldingName == "note_map1" then
getMouseItem():setScrollImage("assets/textures/gui/scroll_images/treasure_map_slime.tga")
elseif wasHoldingName == "note_map2" then
getMouseItem():setScrollImage("assets/textures/gui/scroll_images/treasure_map_vault.tga")
end