Ambiera Forum

Discussions, Help and Support.

Ambiera Forum > CopperCube > Programming and Scripting
gravity

c123
Registered User
Quote
2020-10-07 15:42:45

how to turn of gravity on\off by code


Robo
Guest
Quote
2020-10-08 07:33:05

its not possible unfortunately but you can of course turn off gravity whenever you like....

You can also make use of the code that sets a position without collision - pretty sure no gravity in that case...so I make use of that and the normal situation to get around some gravity issues.


Robo
Guest
Quote
2020-10-08 07:35:00

Var root = ccbGetSceneNodeFromName("root") ;
ccbSetSceneNodeProperty(root, "Gravity", value) ;

https://www.ambiera.com/coppercube/doc/cnt_javascriptref.htmlccbRegisterOnFrameEvent


c123
Registered User
Quote
2020-10-08 08:02:20

thanks robo
could u pls answer to my other 2 questions pls
if u know the answer.


Robo
Guest
Quote
2020-10-21 08:59:51

sorry - just realised the coder is:

var root = ccbGetRootSceneNode();
ccbSetSceneNodeProperty(root, "Gravity", value);


Create reply:


Posted by: (you are not logged in)


Enter the missing letter in: "I?ternational" (you are not logged in)


Text:

 

  

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