Posted August 28, 2023 by Inkus Games
#release #progress
After sever months work we can now release the first Beta candidate. This includes many features we trust you will find useful. Primarily.
After a fair bit of deliberation we are going to keep Infomancer Forge free (with donations should any of you wish to buy us coffee for those late hours)
We ask that you support us in the following ways.
Plugins are now managed online and have version of there own. Also dependencies so that they will include plugin’s and modules they need to function.
This is meant to be a basic dialog you can use to create your own.
The dialogs include a Conversation or source. Dialogs and choices. Additionally it includes a General game and events for triggering and for limiting what is available when.
To make exporting of data more useful it is not customizable per project.
Generally we export to Json but we have also included exporting to Unity. This will create the c3 classes for each of your Gob’s and the general script to download the full exported data. Other game engine will be considered as we get more requests for each.
The c# scripts are build from templates you can also configure for your project.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Newtonsoft.Json;
namespace InformancerForge
{
public class Dialog : GOBInstance
{
public readonly string text;
public readonly Choice[] choices;
public readonly string actionLua;
public readonly bool fallThrough;
public Dialog(JsonReader reader) {
while (reader.Read()) {
if (reader.TokenType == JsonToken.EndObject) {
break;
}
if (reader.TokenType == JsonToken.PropertyName) {
switch (reader.Value) {
case "text": text = ReadString(reader); break;
case "choices":
List<Choice> arrayChoice = new List<Choice>();
for (reader.Read(); reader.TokenType != JsonToken.EndArray;) {
reader.Read();
if (reader.TokenType == JsonToken.StartObject) {
arrayChoice.Add(new Choice(reader));
}else {
// error
break;
}
}
choices=arrayChoice.ToArray();
break;
case "actionLua": actionLua = ReadString(reader); break;
case "fallThrough": fallThrough = ReadBool(reader); break;
default:
//error
break;
}
}
}
}
}
}