Code Monkey home page Code Monkey logo

le-dialogue-editor's People

Contributors

levrault avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

le-dialogue-editor's Issues

Split cache and other sections in the config file

Is your feature request related to a problem? Please describe.
I want to store a dialogues using git. A lot of useful data items (locales, characters, variables) store in the config file. But a cache section changes is dirty changes from the point of view of git index. I dont want to store last_opened_file because it changes everytime.

Describe the solution you'd like
Its better to split nessesary and auxiliary data into separated files. For example, store a cache in the separated cache file in a folder with main config. I think [path] is not necessary for dialogue itself and should to store separetely. Then I can to ignore this files in the git indexation.

Chinese chanracters are not displayed

Describe the bug
I'm writing dialogue on chinese language. But chanracters are not displayed in the node.

image

But they are in a saved json

image

To Reproduce
Steps to reproduce the behavior:

  1. Create dialogue node.
  2. Type chinese or other non-latin character.

Expected behavior
Localization works fine :)

** Files**

[path]

resource="[path-to-project]/test"
OSX=""
Windows="[path-to-project]/test"
UWP=""
X11=""

[configuration]

has_portrait=false
has_name=true
dialogue_character_limit=0
choice_character_limit=0

[locale]

current="zh"
selected=[ "en", "zh" ]
custom=[  ]

[variables]

characters=[ {
"name": "hq",
"portraits": [  ],
"uuid": "5c54ce77-3a52-4435-8fe6-3f2bee5ad662"
}, {
"name": "ber",
"portraits": [  ],
"uuid": "00e2976f-1284-4888-990b-f67cd55dc179"
} ]
files=[ {
"name": "test.json",
"path": "[path-to-project]/test/test.json"
} ]

[cache]

last_opened_file={
"name": "test.json",
"path": "[path-to-project]/test/test.json"
}

[info]

version="v1.1.3"
{"5a25411d-063f-4f1e-ab03-63420b5e03bb":{"name":"hq","character_uuid":"5c54ce77-3a52-4435-8fe6-3f2bee5ad662","text":{"en":"","fr":"","zh":"要"},"parent":"bd06c18b-4797-43d6-a89a-bd387bfe1cd1","choices":[{"text":{"en":"o1","fr":"","ru":"","zh":""},"next":"337b838f-44a8-43df-831a-a80c470798ae","parent":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},{"text":{"en":"o2","fr":"","ru":"","zh":""},"next":"0d90f192-0efc-4ce4-8081-2051aa3ddd47","parent":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},{"text":{"en":"щщщфывфывщo3","fr":"","ru":"123фывфывфывфывфывфыв\nфыв","zh":""},"next":"bd06c18b-4797-43d6-a89a-bd387bfe1cd1","parent":"5a25411d-063f-4f1e-ab03-63420b5e03bb"}]},"337b838f-44a8-43df-831a-a80c470798ae":{"name":"ber","character_uuid":"00e2976f-1284-4888-990b-f67cd55dc179","text":{"en":"haku","fr":"","zh":""},"parent":"29dd51a0-81b5-4e5a-8466-1f1f7ef30518"},"0d90f192-0efc-4ce4-8081-2051aa3ddd47":{"name":"ber","character_uuid":"00e2976f-1284-4888-990b-f67cd55dc179","text":{"en":"fakuфыв","fr":"","zh":""},"parent":"6efbfcd9-76d4-410e-809b-d9c1e10efd17","choices":[{"text":{"en":"wo overpower","fr":"","zh":"","ru":""},"next":"80796358-52e2-4fa3-b291-18226aa8447f","parent":"0d90f192-0efc-4ce4-8081-2051aa3ddd47"},{"text":{"en":"I have overpower","fr":""},"next":"8d8e2e51-0aba-4e00-9799-d941ac2df03c","parent":"966200a9-8293-4bf8-9519-9eb26ae80cbf","uuid":"19dfe969-d97c-4b03-8159-34898af410a2"},{"text":{"en":"I have overpower","fr":"","zh":"","ru":""},"next":"8d8e2e51-0aba-4e00-9799-d941ac2df03c","parent":"966200a9-8293-4bf8-9519-9eb26ae80cbf","uuid":"19dfe969-d97c-4b03-8159-34898af410a2"},{"text":{"en":"I have overpower","fr":"","zh":"","ru":""},"next":"8d8e2e51-0aba-4e00-9799-d941ac2df03c","parent":"966200a9-8293-4bf8-9519-9eb26ae80cbf","uuid":"19dfe969-d97c-4b03-8159-34898af410a2"}],"conditions":[{"parent":"0d90f192-0efc-4ce4-8081-2051aa3ddd47","next":"19dfe969-d97c-4b03-8159-34898af410a2"," overpower":{"value":20,"operator":"greater","type":"int"}}]},"bd06c18b-4797-43d6-a89a-bd387bfe1cd1":{"name":"hq","character_uuid":"5c54ce77-3a52-4435-8fe6-3f2bee5ad662","text":{"en":"ok i give you overpower","fr":"","zh":""},"parent":"dd3781fa-56b2-49af-b2d1-977c78eb38da","signals":{"parent":"bd06c18b-4797-43d6-a89a-bd387bfe1cd1","overpower":{"Number":"100"}},"next":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},"80796358-52e2-4fa3-b291-18226aa8447f":{"name":"hq","character_uuid":"5c54ce77-3a52-4435-8fe6-3f2bee5ad662","text":{"en":"end without","fr":"","zh":""},"parent":"4ae56c4d-6066-4684-a95f-dbc5381c53ed"},"8d8e2e51-0aba-4e00-9799-d941ac2df03c":{"name":"hq","character_uuid":"5c54ce77-3a52-4435-8fe6-3f2bee5ad662","text":{"en":"you have overpower","fr":"","zh":""},"parent":"19dfe969-d97c-4b03-8159-34898af410a2","signals":{"parent":"8d8e2e51-0aba-4e00-9799-d941ac2df03c"}},"root":{"next":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},"__editor":{"root":{"uuid":"root","offset":[40,140]},"dialogues":[{"uuid":"5a25411d-063f-4f1e-ab03-63420b5e03bb","offset":[260,160],"parent":"root"},{"uuid":"337b838f-44a8-43df-831a-a80c470798ae","offset":[1180,160]},{"uuid":"0d90f192-0efc-4ce4-8081-2051aa3ddd47","offset":[1140,540]},{"uuid":"bd06c18b-4797-43d6-a89a-bd387bfe1cd1","offset":[520,1240]},{"uuid":"80796358-52e2-4fa3-b291-18226aa8447f","offset":[2340,460]},{"uuid":"8d8e2e51-0aba-4e00-9799-d941ac2df03c","offset":[2520,840]}],"conditions":[{"uuid":"966200a9-8293-4bf8-9519-9eb26ae80cbf","offset":[1660,840],"parent":"0d90f192-0efc-4ce4-8081-2051aa3ddd47","collapsed":false,"has_choice":true,"data":{"parent":"0d90f192-0efc-4ce4-8081-2051aa3ddd47","next":"19dfe969-d97c-4b03-8159-34898af410a2"," overpower":{"value":20,"operator":"greater","type":"int"}}}],"signals":[{"uuid":"2fc5c140-0698-421a-9610-cbf65b3889b4","offset":[540,1720],"parent":"bd06c18b-4797-43d6-a89a-bd387bfe1cd1","data":{"parent":"bd06c18b-4797-43d6-a89a-bd387bfe1cd1","overpower":{"Number":"100"}}},{"uuid":"e6c187fc-b68d-4fd0-b26b-f05b617a87aa","offset":[3020,920],"parent":"8d8e2e51-0aba-4e00-9799-d941ac2df03c","data":{"parent":"8d8e2e51-0aba-4e00-9799-d941ac2df03c"}}],"choices":[{"uuid":"29dd51a0-81b5-4e5a-8466-1f1f7ef30518","offset":[680,240],"parent":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},{"uuid":"6efbfcd9-76d4-410e-809b-d9c1e10efd17","offset":[700,500],"parent":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},{"uuid":"dd3781fa-56b2-49af-b2d1-977c78eb38da","offset":[660,760],"parent":"5a25411d-063f-4f1e-ab03-63420b5e03bb"},{"uuid":"4ae56c4d-6066-4684-a95f-dbc5381c53ed","offset":[1680,540],"parent":"0d90f192-0efc-4ce4-8081-2051aa3ddd47","data":{"text":{"en":"wo overpower","fr":"","zh":"","ru":""},"next":"80796358-52e2-4fa3-b291-18226aa8447f","parent":"0d90f192-0efc-4ce4-8081-2051aa3ddd47"}},{"uuid":"19dfe969-d97c-4b03-8159-34898af410a2","offset":[2080,880],"parent":"966200a9-8293-4bf8-9519-9eb26ae80cbf","data":{"text":{"en":"I have overpower","fr":"","zh":"","ru":""},"next":"8d8e2e51-0aba-4e00-9799-d941ac2df03c","parent":"966200a9-8293-4bf8-9519-9eb26ae80cbf","uuid":"19dfe969-d97c-4b03-8159-34898af410a2"}}]}}

Screenshots
See above

Desktop (please complete the following information):

  • OS: Windows
  • Version 10

Additional context
Add any other context about the problem here.

Handle signals not present in the __editor block in the json

Describe the bug
For reasons described in #45 I added signals to a text node using text editor. But the dialogue editor starts to crush after it.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
Can you create signal's __editor information with defaults?

** Files**
Everything generated by LE Dialogue Editor (.cfg, .json etc.)

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: Windows
  • Version 4

Additional context
Add any other context about the problem here.

Human-readable json file setting for a workspace

Is your feature request related to a problem? Please describe.

  • Sometime it is easy to change json with dialog from text editor. For example, to fix typos.
  • Changes in a single-line not-intended file is not better to control over git.

Describe the solution you'd like
Add a checkbutton Human-readable dialog's json-files in the workspace settings.

Describe alternatives you've considered
Always store dialogs in a human-readable json.

Store data in config file using relative paths

Is your feature request related to a problem? Please describe.
I want to store a dialogues using git. Its insecure to store absolute paths.

Describe the solution you'd like
Can you load a workspace with relative paths based on config file location?

Root to portraits is not set locally

When creating characters and inserting their respective portraits, the json is exported with the global path and not the local path of the folder

Enviroment:

  • Windows 10 2004

Generated JSON:

{"root":{"next":"34829806-bdc2-4450-9d77-e021f1cffa2b"},"34829806-bdc2-4450-9d77-e021f1cffa2b":{"name":"Godot","portrait":"/Luis Oswaldo/MasterGamer57/testcdddd/1.png","text":{"en":"sasa","fr":""},"next":"cfa4b170-b4bf-42c3-8ca5-337487d1616e"},"cfa4b170-b4bf-42c3-8ca5-337487d1616e":{"name":"sada","portrait":"/Luis Oswaldo/MasterGamer57/testcdddd/rrr/rrr/2.png","text":{"en":"tata","fr":""}},"__editor":{"root":{"uuid":"root","offset":[40,100]},"dialogues":[{"uuid":"34829806-bdc2-4450-9d77-e021f1cffa2b","offset":[240,80],"parent":"root"},{"uuid":"cfa4b170-b4bf-42c3-8ca5-337487d1616e","offset":[780,200]}],"conditions":[],"signals":[],"choices":[]}}

Generated .sfg file:*

[path]

file=""
resource="C:/Luis Oswaldo/MasterGamer57/testcdddd"

[locale]

current="en"
selected=[ "en", "fr" ]
custom=[  ]

[variables]

characters=[ {
"name": "Godot",
"portraits": [ {
"name": "1.png",
"path": "/Luis Oswaldo/MasterGamer57/testcdddd/1.png",
"uuid": "a79de44e-c57b-4758-8e56-f33835ded7aa"
} ]
}, {
"name": "sada",
"portraits": [ {
"name": "2.png",
"path": "/Luis Oswaldo/MasterGamer57/testcdddd/rrr/rrr/2.png",
"uuid": "d18abc4a-e48f-41f0-bdae-d83919ec3ee6"
} ]
} ]
files=[ {
"name": "sasa.json",
"path": "/Luis Oswaldo/MasterGamer57/testcdddd/sasa.json"
} ]

[cache]

last_opened_file={
"name": "unregistred_0.json",
"path": "user://test???.unregistred_0.json"
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.