js callback

08 December 2017 15:57
I have made tutorial
https://www.youtube.com/watch?v=xSMShlFXAu0&t=1s
but something is wrong
I have no idea what I need to do different.

There is one difference between tutorial and my nodes:
in tutorial is "switch select"
in my blend file is "select" but I understand that this is correct.

Please help me!
10 December 2017 17:47
Hello, I think you need the last step of the tutorial, save the Blender file and re-export scene. When you run the .html we can see in the debug console that the jscallback node does not exist.
11 December 2017 10:45
I've saved blend file and I've re-exported scene as you have wrote me - doesn't help ;(
(I've tested few options - export json/html from blender)
I have done this many times and I don't know why this isn't working.
If someone can download files from my firt post and try to solve this for me.
Of course I'm interested in how to solve this - not only in get this specific solved files.
11 December 2017 13:04
I do not know why it does not work !!, just tell you that the version of B4W 17.10.01 is only compatible with version 2.79 of Blender. I personally had problems with this.
11 December 2017 13:30
I have blender 2.79 and Blend4web 17.10.1
11 December 2017 14:05
I have done the tutorial and it works correctly, it could be that for some reason in that project something internal Blender or B4W has failed, you could try to make a new project. I attached the file .blend mine.
13 December 2017 11:20
Hello!
I've tried your blend and js and for me all works. Project is attached. Blend4Web 17.10.1
Alexander (Blend4Web Team)
twitter
14 December 2017 14:36
thx in this case I need to check this one more time ;)
15 December 2017 15:21
I have made this tutorial once again, but this time carefully - and once again the same.
In some reason in my html file is very, very long - I have noticed that Alexander Romanov's html file is shortest.

in some reason I haven't this line:
<script type="text/javascript" src="test1.js"></script>
but instead I have a lot of (nonunderstable for me) long code

I have made addictionally two operation in project manager:
I have clicked Check modules and next update modules.
This helped a little, but file with cube still isn't work.

Addictionally I don't know why my preloader looks different than preloader Alexander Romanov
My is in circle, and Alexander Romanov's is simple bar with progress

PLEASE HELP ME :( I don't know what I do wrong.
15 December 2017 16:09
It seems that in some step you have overwritten your original project HTML with HTML export.
There are two types of outputs you can use during export.

First is HTML export.
You can use it if you want just put your model into one file and you have no javascript code.
How it works: Addon use some html template with builtin webplayer and injecting all your data regarding your 3d model: this is json with metadata, bin with geometry, all textures and videos. So as an output you have one large html.

Another type is JSON export.
The output is Json and bin files. To use this type of output you should write your own Bled4Web application or use webplayer to load it. In case of your app you should create html, insert script tags with engine core and your application code. Project manager can do it for you when you are creating a project. Then if you've modified your model or logic nodes, you should export to JSON and choose the correct file (by default it is already correct).

So HTML-export is bundle which include webplayer, and your model
JSON-export is like an export of resources which Blend4Web engine can load:
m_data.load(APP_ASSETS_PATH + "simple_app.json", load_cb, preloader_cb);
Alexander (Blend4Web Team)
twitter
 
Please register or log in to leave a reply.