Organize assets
This commit is contained in:
+16
-1
@@ -10,6 +10,7 @@ import iron.object.Object;
|
||||
import arm.render.Inc;
|
||||
import arm.render.RenderPathDeferred;
|
||||
import arm.Config;
|
||||
using StringTools;
|
||||
|
||||
class Main {
|
||||
|
||||
@@ -42,7 +43,17 @@ class Main {
|
||||
if (c.window_maximizable) windowFeatures |= FeatureMaximizable;
|
||||
if (c.window_minimizable) windowFeatures |= FeatureMinimizable;
|
||||
|
||||
System.start({title: "untitled - ArmorPaint", width: c.window_w, height: c.window_h, window: {mode: windowMode, windowFeatures: windowFeatures}, framebuffer: {samplesPerPixel: c.window_msaa, verticalSync: c.window_vsync}}, function(window:Window) {
|
||||
#if arm_player
|
||||
var title = Krom.getArg(0);
|
||||
title = title.replace("\\", "/");
|
||||
var lasti = title.lastIndexOf("/");
|
||||
if (lasti >= 0) title = title.substr(lasti + 1);
|
||||
if (title.endsWith(".exe")) title = title.substr(0, title.length - 4);
|
||||
#else
|
||||
var title = "untitled - ArmorPaint";
|
||||
#end
|
||||
|
||||
System.start({title: title, width: c.window_w, height: c.window_h, window: {mode: windowMode, windowFeatures: windowFeatures}, framebuffer: {samplesPerPixel: c.window_msaa, verticalSync: c.window_vsync}}, function(window:Window) {
|
||||
iron.App.init(function() {
|
||||
Scene.setActive("Scene", function(object:Object) {
|
||||
var path = new RenderPath();
|
||||
@@ -50,7 +61,11 @@ class Main {
|
||||
RenderPathDeferred.init(path);
|
||||
path.commands = RenderPathDeferred.commands;
|
||||
RenderPath.setActive(path);
|
||||
#if arm_player
|
||||
new arm.Player();
|
||||
#else
|
||||
new arm.App();
|
||||
#end
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user