roblox dictionary key code example

Example: create a dictionary in roblox

-- Add a Module Script into the ServerScriptStorage

local speechMod = {}

	speechMod.speech = {
		["quest1"] = {	
			["line1"] = "Hi this is quest 1",
			["line2"] = "I have a Quest for you",
			["line3"] = "Come back when your done"
		}, -- end quest1
	
		["quest2"] = {	
			["line1"] = "Hi this is quest 2",
			["line2"] = "You have completed quest 1, great",
			["line3"] = "Get me some Food bro"
		} -- end quest2
	} -- end speechMod.speech


return speechMod

-- LUA Scripting Language (For Making Games in Roblox)

Tags:

Misc Example