Ambiera ForumDiscussions, Help and Support. |
|
|
|||||
|
Hello, I'm trying to use load function (engine.load("somename.ccbjs", true, function(){ alert('is now loaded!')); ) under CC. Is it possible ? How ? Regards, |
||||
|
It works when you are using the CopperLicht SDK. Just replace the copperlicht.js file with the one from the SDK. On its website, you will also find the documentation for that: http://www.ambiera.com/copperlic... |
||||
|
Sorry Niko, I'm not sure I understood. I did that : - extracting copperlicht.js form copperlicht SDK 1.10. - Put (replacing) it in the only place where I could see an other copperlicht.js : The copperlichtData of my CC application. (I thought CC use a central copperlicht.js file and because of that it was located in CC's directory, I was wrong. I found tons of copperlicht.js in each copperlichtdata folders ! There all the same ! So why ?) --> Nothing change, engine still not recognized. Please Niko explain me step by step what I must do for being able to use load function under CC. Or I didn't understood and you meant it is impossible. I'm lost. HELP ! I need somebody's help !! |
||||
|
You need to be sure that you are really using the right one. Note that CopperCube is overwriting the files (your html and the .js) everytime you publish. So you could for example put them into another directory, or rename them slightly and link them from another file, whatever you prefer. If you need help with tasks like this, this sounds like you might have not that much experience with programming (just a guess, no offence), so maybe it would be easier for you to use the other solution with multiple .html files instead, this wouldn't need any programming then. |
||||
|
I don't want to use web page switching. This code, under CC: engine.load("EssaiLoadSceneVibrionDroiteGauche.ccbjs", true); Send a "engine" not defined message and don't load anything under html. Ok. I thought startCopperLichtFromFile() function created such a named instance of CopperLicht ("engine") class but I was wrong. So I tried add "engine" instanciation as global var in the Html : engine = startCopperLichtFromFile('3darea',.....); And it works, except that scene's loading doesn't end because all textures are not found (7/14) It is strange because I uncheked "wait until textures loaded" in htlm publications parameters of that loaded scene. If I would have known how I can make reference to the CopperLicht class created by the .exe I thinck I could do the same with exe. Niko ? |
||||
|
Will take a look into that, thanks for reporting. |
||||
|
Ok. How can I make reference to engine object with .exe Niko ? I can't change the .html ! Does engine object is a child of windows object ? Or windows.documents object ? |
|