Blender game calling a HTML file

Can a Blender game, running in the browser with the plugin, call another HTML file, upon a mouse click on a certain area, or keystroke?
Or, can i call another Blend file? I know it call call up another scene, but I would like to have a solution that doesn´t preload all scenes, for the sake of the file size.

Look at, in heading “Jumping to another HTML page”.
I used this feature to show and save score from game.

Thanks ashsid! That does the trick!

Do you know if it is possible to open that page on another (new) window or in a specific frame on the main (game) browser window?

It seems that it allows only opening new page in the same window or frame.

can’t you add a target="_blank" to the url and make it open in a new window?

No, because it considers it as a part of url and returns “no page found” error.

curious: could you put javascript in there?“”)

I don’t have the plugin installed at the moment to test it

Good idea, z3r0 d!
I tried to implement it but bumped in this problem: that field accepts only 31 characters. I could manage to fit only this wrong URL into the message“http://”).
It kind of worked, popping a new window with a “http://” content, but it made the blender game disapear from the other (original) window, leaving a [object] text message.
So if the correct (long) URL could be passed as a variable… and the game didn´t disapear…
Thanks z3r0 d, at least we know now that javascript can be triggered.

can python set the body to longer than 31 characters?

(or if a property works… yeah)

after testing, apparently yes

possibly some other quirks, but:

a = GameLogic.getCurrentController().getActuators()[0]
GameLogic.addActiveActuator(a, 1)

does seem to work as expected (only expects one properly filled message actuator connected to it btw)

this could probably be rewritten slightly to be used with a string property of the object, if you like

Good to see that someone is still working with web plugin. Contact me via pm. I want to use it to do interactive demos,presentations and online multiplayer game(if I can. that seems to be a problem) I would REALLY LOVE to BRAINBUZZ with somone that is still using it.

Ok SHABA1, we can talk some after the weekend. Here´s my MSN contact [email protected]

hey guys

Im using the blender plugin technology for my “myst translations” project.
Its almost perfect for the concept of linking between ages/worlds (see one of my earlier posts for details).

Im using the message actuator with a url contained in a variable (similar to this suggestion by somebody else in this forum)

make a new string property with this value:
javascript: var‘yourfile.html’,’’,‘width=320 height=200’); w.focus();

and set the Message to
To: host_application
Subject: load_url
change the message type to ‘Propname’ and put the property name you just created in that.

this seemed to work ok when i tested it. (winxp, ie6, blender plugin).

glad to see others looking at the blender plugin - hopefully some interest will spark some development in that area (although i think its very usable as is)



Way to go, barry! Thanks a lot for this solution. I was heading towards defining some javascripts in the HTML and calling them from Blender. But your approach is all within Blender. Great!

Barry, I tested it it works just fine. Thanks again!

no problems alex

are you using this in your virtual brasil project or are you working on something else ?



Yes, that will be for Virtual Brasília.

The example on had an absolute link. I’m just wondering, can it accept relative links?

The javascript example on this thread can handle relative paths.

Is there a way for Blender to open a HTML page in another frame?