Commit 68e5a634 authored by Max Bebök's avatar Max Bebök

chg: support dungeons in editor and map

parent d8cc0afc
......@@ -5,26 +5,23 @@ The current released and prebuilt stable version is: **2.1.0**
<hr/>
### WIP - Version 2.3.0 - "Convenience Update"
**General** <br/>
#dev - Clone / Add now generates a new HashId
<hr/>
### WIP - Version 2.2.0 - "Convenience Update"
**Field + Shrine Editor** <br/>
#54 - actor-search, use Ctrl+F to open a window to search for actors by name, IDs and params <br/>
#53 - added history, use the controls at the top or CTRL+Z / CTRL+Y to undo/redo changes <br/>
#53 - added history, use the controls at the top or CTRL+Z / CTRL+Y to undo/redo changes (slow in field-editor) <br/>
#36 - actor-tools: the actor type (Dynamic/Static) can now be changed <br/>
#36 - actor tools: added focus button that positions the camera near the actor and looks at it <br/>
#36 - actor tools: added de-select button <br/>
#36 - actors can now be selected with right and/or middle click (see global settings) <br/>
#36 - added a button in the launcher to open the Wiki <br/>
#dev - Clone / Add now generates a new HashId <br/>
#dev - Adding actors (buttons on the left side in shrine/field editor) <br/>
#dev - Actor templates added (left side), allow easy creation of event systems like doors
#dev - experimental visualization of actor links in 3d-view (render-settings on the left, very slow in field editor)
**Mubin-Logic Viewer** <br/>
#dev - added very experimental mubin-logic viewer, right now it only views data
#dev - added very experimental mubin-logic viewer, right now it only views data <br/>
**Launcher** <br/>
#55 - right after starting, support for WebGL2 is checked to avoid later errors, if unsupported a message is shown <br/>
......@@ -32,6 +29,9 @@ The current released and prebuilt stable version is: **2.1.0**
**Model-Viewer** <br/>
#11 - opening new BFRES file reloads the window instead on manually deleting old stuff (less RAM usage) <br/>
**Bug-Fixes** <br/>
#dev - Actors are now correctly sorted when saved as a mubin <br/>
<hr/>
### Version 2.1.0 - "Field-Editor + Map"
......
......@@ -14,6 +14,7 @@ const Notify = requireGlobal("lib/notify/notify.js");
const Filter = requireGlobal("lib/filter.js");
const Field_Editor = require("./lib/field_editor.js");
const ActorParams = require('../../lib/mubin_editor/actor/params');
const String_Table = requireGlobal("lib/string_table/string_table.js");
const extractField = require("./lib/field_extractor");
const extractStaticMubins = require("./lib/static_mubin_extractor");
......@@ -58,6 +59,19 @@ module.exports = class App extends App_Base
this.node.querySelector(".data-tool-openTitleBgDir").onclick = () => {
electron.shell.showItemInFolder(path.join(this.project.getPath(), "TitleBG.pack"));
};
this.node.querySelector(".data-tool-addActorStatic").onclick = async () => {
this.fieldEditor.actorHandler.addFromData(ActorParams.createTemplate("FldObj_HugeMazeTorchStand_A_01"), "Static");
};
this.node.querySelector(".data-tool-addActorDyn").onclick = async () => {
this.fieldEditor.actorHandler.addFromData(ActorParams.createTemplate("FldObj_HugeMazeTorchStand_A_01"), "Dynamic");
};
this.node.querySelector(".data-tool-addActorTemplate").onclick = async () => {
const templateName = this.node.querySelector(".data-tool-actorTemplate").value;
this.fieldEditor.actorHandler.addFromTemplate(templateName);
};
}
......
......@@ -7,7 +7,7 @@
const QuerySelector_Cache = require("./../../../../lib/queryselector_chache");
const FIELD_SECTION_REGEX = /[A-J]-[1-9]/;
const SHRINE_REGEX = /Dungeon[0-9]{3}/;
const SHRINE_REGEX = /(Dungeon[0-9]{3})|(Remains.+)/;
module.exports = class World_Map_UI
{
......
......@@ -56,12 +56,6 @@ module.exports = class Shrine_Creator
this.saveActors("Static", shrineDir, shrineName),
]);
const cemuPackPath = "/home/mbeboek/graphicPacks/BreathOfTheWild_EventTest/content/Pack/Dungeon059";
await Promise.all([
this.saveActors("Dynamic", cemuPackPath, shrineName),
this.saveActors("Static", cemuPackPath, shrineName),
]);
if(packData)
{
const sarc = new SARC();
......@@ -78,7 +72,9 @@ module.exports = class Shrine_Creator
*/
async saveActors(typeName, shrineDir, shrineName)
{
const actorPath = path.join(shrineDir, "Map", "CDungeon", shrineName, `${shrineName}_${typeName}.smubin`);
const mapDir = shrineName.startsWith("Remains") ? "MainFieldDungeon" : "CDungeon";
const actorPath = path.join(shrineDir, "Map", mapDir, shrineName, `${shrineName}_${typeName}.smubin`);
const byaml = new BYAML.Creator();
const byamlData = {...(typeName == "Dynamic" ? this.actorHandler.dataActorDyn : this.actorHandler.dataActorStatic)};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment