-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHelloWorldLoop.luau
More file actions
38 lines (31 loc) · 1.14 KB
/
HelloWorldLoop.luau
File metadata and controls
38 lines (31 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
--!strict
local dialogueMakerKit = script.Parent.Parent; -- Replace with your own path to the DialogueMakerKit folder.
local Client = require(dialogueMakerKit.Packages.Client);
local Conversation = require(dialogueMakerKit.Packages.Conversation);
local Message = require(dialogueMakerKit.Packages.Message);
local Response = require(dialogueMakerKit.Packages.Response);
local Redirect = require(dialogueMakerKit.Packages.Redirect);
local StandardTheme = require(dialogueMakerKit.Packages.StandardTheme);
-- Create a new conversation.
local conversation = Conversation.new({}, {
[1] = Message.new("Hello, world!", {}, {
[1] = Response.new("Hello, world!", {}, {
[1] = Redirect.new({}, function(self)
return {self:getConversation():getNextVerifiedDialogue()}
end);
});
[2] = Response.new("Goodbye, world!", {}, {
[1] = Message.new("H-huh!? You weren't supposed to do that! You gotta get outta here before they find out!");
})
});
});
-- Start the conversation.
Client.new({
dialogue = conversation:getNextVerifiedDialogue();
settings = {
theme = {
component = StandardTheme
};
};
});
return {};