make slick the install process

This commit is contained in:
Mike 2019-02-12 22:48:11 -08:00
parent 5b29f8e3cc
commit b2a1c60372
4 changed files with 34 additions and 19 deletions

1
.gitignore vendored
View File

@ -1,4 +1,5 @@
.DS_Store
.vs
FNA/
ImGui.NET/
fnalibs/

View File

@ -122,40 +122,50 @@ function getLibs()
# Get the directory of this script
MY_DIR=$(dirname "$BASH_SOURCE")
# gather input
# FNA
if [ ! -d "$MY_DIR/FNA" ]; then
read -p "Download FNA (y/n)? " shouldDownload
if [[ $shouldDownload =~ ^[Yy]$ ]]; then
downloadFNA
fi
else
read -p "Update FNA (y/n)? " shouldUpdate
if [[ $shouldUpdate =~ ^[Yy]$ ]]; then
updateFNA
fi
fi
# FNALIBS
if [ ! -d "$MY_DIR/fnalibs" ]; then
read -p "Download fnalibs (y/n)? " shouldDownloadLibs
else
read -p "Redownload fnalibs (y/n)? " shouldDownloadLibs
fi
# Dear ImGui
if [ ! -d "$MY_DIR/ImGui.NET" ]; then
read -p "Download ImGui.NET (y/n)? " shouldDownload
else
read -p "Update ImGui.NET (y/n)? " shouldUpdate
fi
# act on the input
# FNA
if [[ $shouldDownload =~ ^[Yy]$ ]]; then
downloadFNA
elif [[ $shouldUpdate =~ ^[Yy]$ ]]; then
updateFNA
fi
# FNALIBS
if [[ $shouldDownloadLibs =~ ^[Yy]$ ]]; then
getLibs
fi
# Dear ImGui
if [ ! -d "$MY_DIR/ImGui.NET" ]; then
read -p "Download ImGui.NET (y/n)? " shouldDownload
if [[ $shouldDownload =~ ^[Yy]$ ]]; then
downloadImGui
fi
else
read -p "Update ImGui.NET (y/n)? " shouldUpdate
if [[ $shouldUpdate =~ ^[Yy]$ ]]; then
updateImGui
fi
if [[ $shouldDownload =~ ^[Yy]$ ]]; then
downloadImGui
elif [[ $shouldUpdate =~ ^[Yy]$ ]]; then
updateImGui
fi

View File

@ -14,9 +14,13 @@ namespace project_name
#if DEBUG
System.Diagnostics.Debug.Listeners.Add(new System.Diagnostics.TextWriterTraceListener(System.Console.Out));
#endif
// setup a Scene so we have something to show
var newScene = new Scene();
newScene.addRenderer(new DefaultRenderer());
// optionally render Nez in an ImGui window
newScene.finalRenderDelegate = new ImGuiFinalRenderDelegate();
var logo = newScene.content.Load<Microsoft.Xna.Framework.Graphics.Texture2D>("nez-logo-black");
newScene.createEntity("logo")

View File

@ -39,7 +39,7 @@ namespace Nez
Core.graphicsDevice.Clear( letterboxColor );
_imGuiRenderer.BeforeLayout(new GameTime(TimeSpan.FromDays(0), TimeSpan.FromMilliseconds(Time.deltaTime * 1000)));
_imGuiRenderer.BeforeLayout(Time.time);
layoutGui();
_imGuiRenderer.AfterLayout();
}