From 912749d2520afedd9b56458d771400c261fe2b88 Mon Sep 17 00:00:00 2001 From: Normand Briere <nbriere@noware.ca> Date: Thu, 08 Aug 2019 20:56:19 -0400 Subject: [PATCH] All textures working. --- CameraPane.java | 24 +++++++++++++++++------- 1 files changed, 17 insertions(+), 7 deletions(-) diff --git a/CameraPane.java b/CameraPane.java index 219e567..df56b97 100644 --- a/CameraPane.java +++ b/CameraPane.java @@ -8358,7 +8358,7 @@ // else // if (!texname.startsWith("/")) // texname = "/Users/nbriere/Textures/" + texname; - if (!FileExists(texname)) + if (!FileExists(texname) && !texname.startsWith("@")) { texname = fallbackTextureName; } @@ -8441,6 +8441,15 @@ new Exception().printStackTrace(); } else { + if (texname.startsWith("@")) + { + // texturecache = textures.get(texname); // suspicious + if (texturecache == null) + texturecache = new CacheTexture(GetResourceTexture(texname.substring(1), bump),resolution); + else + new Exception().printStackTrace(); + } else + { if (textureon) { String cachename = texname; @@ -8500,6 +8509,7 @@ texturecache = new CacheTexture(texturedata,resolution); //texture = GetTexture(tex, bump); } + } } //} } @@ -10841,7 +10851,7 @@ if (wait) { - Sleep(500); + Sleep(200); // blocks everything wait = false; } @@ -11379,7 +11389,7 @@ // if (cam != lightCamera) //for (int count = parentcam.GetTransformCount(); --count>=0;) - LA.xformDir(lightposition, parentcam.GlobalTransform(), lightposition); // may 2013 + LA.xformDir(lightposition, parentcam.GlobalTransformInv(), lightposition); // may 2013 } LA.xformDir(lightposition, cam.toScreen, lightposition); @@ -14632,9 +14642,9 @@ MODIFIERS |= COMMAND; /**/ if((mod&SHIFT) == SHIFT) - manipCamera.RotatePosition(0, -speed); - else manipCamera.BackForth(0, -speed*delta, 0); // getWidth()); + else + manipCamera.RotatePosition(0, -speed); /**/ if ((mod & SHIFT) == SHIFT) { @@ -14653,9 +14663,9 @@ MODIFIERS |= COMMAND; /**/ if((mod&SHIFT) == SHIFT) - manipCamera.RotatePosition(0, speed); - else manipCamera.BackForth(0, speed*delta, 0); // getWidth()); + else + manipCamera.RotatePosition(0, speed); /**/ if ((mod & SHIFT) == SHIFT) { -- Gitblit v1.6.2