Delightex Nova allows you to collaborate and play together with others through its multiplayer Experiences.
In this tutorial, you’ll learn how to create and explore your first multiplayer session step by step.
Adding NPCs
In the previous lesson, we learned about custom properties, a powerful way to share and manage game state across all players in a multiplayer session. Now, let’s use this concept to bring NPCs (non-player characters) to life and make them react consistently for everyone.
Start by adding two characters in the Scene Editor — for example, a policeman and a doctor. Then, add the following code to your script:
1let policeman = Scene.getItem("Police man");
2let doctor = Scene.getItem("Doctor woman");
3
4policeman.input.onClick(() => {
5 if (policeman.getProperty("talkedTo") !== "true") {
6 policeman.setProperty("talkedTo", "true");
7 policeman.speech = "Lorem ipsum dolor sit amet";
8 Time.schedule(5, () => policeman.speech = "");
9 }
10});
11
12doctor.input.onClick(() => {
13 if (doctor.getProperty("talkingTo") === "true") {
14 return;
15 }
16
17 doctor.setProperty("talkingTo", "true");
18
19 if (policeman.getProperty("talkedTo") !== "true") {
20 doctor.speech = "Talk first with the policeman";
21 } else {
22 doctor.speech = "ad senserit signiferumque nam, et lorem fugit deseruisse pri";
23 }
24
25 Time.schedule(5, () => {
26 doctor.setProperty("talkingTo", "false");
27 doctor.speech = "";
28 });
29});Now, all players will experience the same NPC behavior. For instance, the doctor will only talk to players after someone has already spoken to the policeman. This happens because the NPCs share their interaction state through custom properties.
By using this technique, you can create much richer multiplayer logic: from quests and dialogues to puzzles or event triggers that stay synchronized across all players. Custom properties give you full control to make your multiplayer world feel alive and consistent for everyone involved!
With these lessons complete, you now have all the essentials to build rich, interactive multiplayer Experiences in Delightex Nova. From joining sessions to adding animation, player interactions, cleanup logic, and NPC behavior, you’re ready to create your own connected worlds. Keep experimenting, expanding your ideas, and bringing your multiplayer visions to life.