≡
Products
▼
Support
▼
Company
▼
Forum
Ambiera Forum
Discussions, Help and Support.
Create a new account
,
Search
, or Login:
Create reply in
Point light cast no shadow?
Posted by:
(you are not logged in)
Enter the missing letter in: "Intern?tional"
(you are not logged in)
Text:
[quote][b][/b] wrote: Thanks a lot for the code and the hints :) Though, I was not sure why is you code working so I reverted your code slowly piece by piece back in to my version and it seems like the problem was that I used my if statement after setting the Direction property of the Node. I'm not sure why maybe it got something to do with the scopes in JS that I don't understand fully to be honest, but it seems like if I was using both if statement before I set the Direction property of the node it is solved the problem on it own: [code]if(direction.x <= 1.0) {direction.x += 0.01} if(direction.x > 1.0) {direction.x = -0.2} ccbSetSceneNodeProperty(sun, "Direction", direction.x, direction.y, direction.z);[/code] I know using if-elseif is more cleaner but I was just curious why. But, It is solved the problem only on Windows. In WebGL I get this error message in the console: [code]XML Parsing Error: not well-formed Location: http://....../Temp/copperlichtdata/coppercube.ccbjs Line Number 1, Column 530: coppercube.ccbjs:1:530 Error: NaN[/code] And the scene is dark right from the start. Any idea why that is?[/quote]
Possible Codes
Feature
Code
Link
[url] www.example.com [/url]
Bold
[b]bold text[/b]
Image
[img]http://www.example.com/image.jpg[/img]
Quote
[quote]quoted text[/quote]
Code
[code]source code[/code]
Emoticons
Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact