Skip to content

Commit

Permalink
Dynamic lights now respect whether lighting is enabled or not.
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuaskelly committed Apr 12, 2020
1 parent 268bd13 commit 782bb99
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.badlogic.gdx.math.Interpolation;
import com.badlogic.gdx.math.Vector3;
import com.interrupt.dungeoneer.GameManager;
import com.interrupt.dungeoneer.annotations.EditorProperty;
import com.interrupt.dungeoneer.game.Game;
import com.interrupt.dungeoneer.game.Level;
Expand Down Expand Up @@ -153,7 +154,11 @@ else if(lightType == LightType.sin_fast) {

@Override
public void tick(Level level, float delta)
{
{
if (!GameManager.renderer.enableLighting) {
return;
}

updateLightColor(delta);

if(isActive && (on || (toggleLerpTime > 0 && toggleLerpTime < 1))) {
Expand Down

0 comments on commit 782bb99

Please sign in to comment.