≡
Products
▼
Support
▼
Company
▼
Forum
Ambiera Forum
Discussions, Help and Support.
Create a new account
,
Search
, or Login:
Create reply in
Something Wierd
Posted by:
(you are not logged in)
Enter the missing letter in: "In?ernational"
(you are not logged in)
Text:
[quote][b]Zoo[/b] wrote: Hi All, I am trying to cycle through this array and I am doing so succesfully... When it gets to a certain point in the array I run this if statement [code] if ( TurnoverDensity > 0 && TurnoverDensity < 12000 ) { print(TurnoverDensity ); print("red"); //Trading Density Bar var sourceNode = ccbGetSceneNodeFromName("ShopToClone"); var newscenenode = ccbCloneSceneNode(sourceNode); ccbSetSceneNodePositionWithoutCollision(newscenenode, Why, 0 , Ex); ccbSetSceneNodeProperty(newscenenode, "Scale", 0.5, 10,0.5); var tex = ccbLoadTexture("img/red10.png"); ccbSetSceneNodeMaterialProperty(newscenenode, 0, "Texture1", tex); //Label var sourceNode2 = ccbGetSceneNodeFromName("LabelToClone"); var newscenenode2 = ccbCloneSceneNode(sourceNode2); ccbSetSceneNodePositionWithoutCollision(newscenenode2, Why + 10, 300 , Ex + 10); var tex2 = ccbLoadTexture("Labels/" + shop + ".png"); ccbSetSceneNodeMaterialProperty(newscenenode2, 0, "Texture1", tex2); //Line var sourceNode = ccbGetSceneNodeFromName("Line"); var newscenenode = ccbCloneSceneNode(sourceNode); ccbSetSceneNodePositionWithoutCollision(newscenenode, Why, 0 , Ex); ccbSetSceneNodeProperty(newscenenode, "Scale", 0.05, 58.5,0.05); var tex = ccbLoadTexture("img/red10.png"); ccbSetSceneNodeMaterialProperty(newscenenode, 0, "Texture1", tex); }[/code] There are 5 different if statements with different values for TurnoverDensity variable. Everything works correctly except the colors come out wrong. I am assigning the colors as textures red10 is the first colour... But even though the scene node is positioned correctly and the label is positioned correctly, the color is wrong... Iam stumped, any help?[/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