Super simple, but for those of you that are running ORTS and have Rashid changing locations this may be a good addition to have just to inform players where he's currently staying.
Link to Github // NPC Location Change: orts2/data/scripts/globalevents/npc_spawn/rashid.lua at main · EPuncker/orts2 (https://github.com/EPuncker/orts2/blob/main/data/scripts/globalevents/npc_spawn/rashid.lua)
Uses the same dialog as Tibia Wiki to describe where he is, so figured that saves a web search for the player.
Create rashidLocation.lua and place inside data/scripts/creaturescripts:
Hope it helps anyone in need!
Link to Github // NPC Location Change: orts2/data/scripts/globalevents/npc_spawn/rashid.lua at main · EPuncker/orts2 (https://github.com/EPuncker/orts2/blob/main/data/scripts/globalevents/npc_spawn/rashid.lua)
Uses the same dialog as Tibia Wiki to describe where he is, so figured that saves a web search for the player.
Create rashidLocation.lua and place inside data/scripts/creaturescripts:
Lua:
local loginEvent = CreatureEvent("onLogin_rashidLocation")
loginEvent:type("login")
local rashidLocations = {
["Monday"] = "Svargrond, in Dankwart's tavern, south of the temple.",
["Tuesday"] = "Liberty Bay, in Lyonel's tavern, west of the depot.",
["Wednesday"] = "Port Hope, in Clyde's tavern, west of the depot.",
["Thursday"] = "Ankrahmun, in Arito's tavern, above the post office.",
["Friday"] = "Darashia, in Miraia's tavern, south of the guildhalls.",
["Saturday"] = "Edron, in Mirabell's tavern, above the depot.",
["Sunday"] = "Carlin depot, one floor above."
}
function loginEvent.onLogin(player)
local currentDayOfWeek = os.date("%A")
local rashidLocationMessage = "Rashid is currently visiting " .. rashidLocations[currentDayOfWeek]
player:sendTextMessage(MESSAGE_STATUS_DEFAULT, rashidLocationMessage)
return true
end
loginEvent:register()
Hope it helps anyone in need!
Last edited: