Directional Light get/set

This commit is contained in:
Dane Johnson
2021-03-04 10:41:45 -06:00
parent 6e19b44981
commit 4c6b4587c3
4 changed files with 25 additions and 4 deletions

View File

@@ -37,7 +37,7 @@ function init()
camera:Translate(couch.Vector3(0.0, 0.0, 10.0))
local light = couch.DirectionalLight()
light.direction = couch.Vector3(0.0, -1.0, -1.0)
light:SetDirection(couch.Vector3(0.0, -1.0, -1.0))
light:SetColor(couch.Vector3(1.0, 1.0, 1.0))
light:SetAmbient(0.2)
light:SetDiffuse(1.0)