topical media & game development
mobile-query-three-plugins-ogsworkshop-examples-post-01.htm / htm
<!-- initialize the web page and load the library -->
<!doctype html><title>Chat And Fight 01 - Let's Build a World</title>
<script src="../../../build/tquery-bundle-require.js"></script>
<body><script>
// load tQuery plugins with require.js
require(['tquery.minecraft', 'tquery.skymap', 'tquery.grassground'], function(){
// create world
var world = tQuery.createWorld().boilerplate().start();
// add a human on it, well a minecraft character
tQuery.createMinecraftChar().addTo(world);
// add a skybox
tQuery.createSkymap('skybox').addTo(world);
// add a ground
tQuery.createGrassGround({
textureRepeatX : 5,
textureRepeatY : 5
}).addTo(world).scaleBy(80);
// quite easy now ?
})
</script></body>
(C) Æliens
04/09/2009
You may not copy or print any of this material without explicit permission of the author or the publisher.
In case of other copyright issues, contact the author.