Nuklear renders in GUI pass
This commit is contained in:
parent
172af950e8
commit
3f2ae7ff82
|
@ -1 +1,2 @@
|
|||
# Yugine Input Guide
|
||||
|
||||
|
|
|
@ -347,11 +347,15 @@ void openglRender(struct window *window) {
|
|||
////// TEXT && GUI
|
||||
|
||||
debug_nextpass();
|
||||
|
||||
nuke_start();
|
||||
|
||||
call_gui();
|
||||
|
||||
debug_flush(&hudproj);
|
||||
text_flush(&hudproj);
|
||||
nuke_start();
|
||||
|
||||
// nuke_start();
|
||||
call_nk_gui();
|
||||
nuke_end();
|
||||
|
||||
|
|
|
@ -128,6 +128,7 @@ var editor = {
|
|||
|
||||
input_o_pressed() {
|
||||
if (this.sel_comp) return;
|
||||
|
||||
if (Keys.ctrl() && Keys.alt()) {
|
||||
if (this.selectlist.length === 1 && this.selectlist[0].file) {
|
||||
if (this.edit_level.dirty) return;
|
||||
|
@ -145,8 +146,10 @@ var editor = {
|
|||
}
|
||||
|
||||
if (Keys.ctrl()) {
|
||||
if (this.check_level_nested())
|
||||
if (this.check_level_nested()) {
|
||||
Log.warn("Nested level ...");
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.edit_level.dirty) {
|
||||
this.openpanel(gen_notify("Level is changed. Are you sure you want to close it?", function() {
|
||||
|
@ -1341,7 +1344,6 @@ var editor = {
|
|||
});
|
||||
|
||||
Debug.draw_grid(1, editor_config.grid_size/editor_camera.zoom);
|
||||
|
||||
var startgrid = screen2world([-20,Window.height]).map(function(x) { return Math.snap(x, editor_config.grid_size); }, this);
|
||||
var endgrid = screen2world([Window.width, 0]);
|
||||
|
||||
|
@ -2530,10 +2532,11 @@ var limited_editor = {
|
|||
};
|
||||
|
||||
set_pawn(editor);
|
||||
Log.warn(`Total pawn count is ${Player.players[0].pawns.length}`);
|
||||
register_gui(editor.ed_gui, editor);
|
||||
Debug.register_call(editor.ed_debug, editor);
|
||||
|
||||
if (IO.exists("editor.config"))
|
||||
load_configs("editor.config");
|
||||
editor.edit_level = Level.create();
|
||||
|
||||
Log.warn('bottom of editor');
|
||||
|
|
|
@ -1502,8 +1502,9 @@ var Level = {
|
|||
|
||||
dup(level) {
|
||||
level ??= this.level;
|
||||
|
||||
Log.warn("Duplicating a level!");
|
||||
var n = level.spawn(this.from);
|
||||
/* TODO: Assign this's properties to the dup */
|
||||
return ;n
|
||||
},
|
||||
|
||||
create() {
|
||||
|
@ -1570,6 +1571,8 @@ var Level = {
|
|||
newlevel.scriptfile = scriptfile;
|
||||
}
|
||||
|
||||
newlevel.from = scriptfile.replace('.js','');
|
||||
|
||||
newlevel.run();
|
||||
|
||||
return newlevel;
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
sim_start();
|
||||
|
||||
|
||||
if (!IO.exists("game.js"))
|
||||
load("scripts/nogame.js");
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue