Dienstag, 6. Dezember 2016

Animate / Fade Intensity

let animation2 = CAKeyframeAnimation()
animation2.keyPath = "geometry.firstMaterial.diffuse.intensity"
animation2.values   =  [2, 0.2, 0.1, 0]
animation2.keyTimes =  [0, 0.5, 0.9, 3]
animation2.duration =  3
animation2.isAdditive = false

self.addAnimation(animation2, forKey: "test2")

Variable im Printtext


Jedesmal muss ich nachgucken. Deshalb schreibe ichs mir hier nieder:

print("Variable: \(variable)")