---------------------------
---------------------------
-- Water fx example
-- Copyright (c) 2007-09 Capricorn 76 Pty. Ltd.
--
-- The water fx is part of the
-- graphics engine and will ripple the surface
-- of the 3D model to simulate water.
--
-- NOTE:
-- The ./Demos/runDemo.e76script is a utility script used to run all the examples.
-- It loads the world, calls the OnWorldLoad(), OnWorldUnload() functions, and runs the graphics engine loop, waiting for the user to press escape.
---------------------------
---------------------------
---------------------------
-- runDemo.e76script calls this function when the world is loaded
---------------------------
function OnWorldLoad(worldName)
--print('OnWorldLoad');
---------------------------
-- The SDK world editor creates a worldIds.e76script when the world is saved. It contains all the entity ids.
-- We load the IDs so that we can refer to the world entities using friendly names.
---------------------------
IApp:loadScript(IWorld:getNameLong() .. '/worldIds');
---------------------------
-- Load this example's GUI
---------------------------
OnWorldLoadGui();
-- Increase the sale of the water entity (make it a little bigger than it was originally created)
IWorld:setEntityScale(idWater_water1, '20 20 20');
end
---------------------------
-- Load example's GUI
---------------------------
function OnWorldLoadGui()
IGraphics:loadGui('help');
end
---------------------------
-- runDemo.e76script calls this function when the world is unloaded
---------------------------
function OnWorldUnload(worldName)
--print('OnWorldUnload');
end
Copyright © 2006-23 Sep 2009 Capricorn 76 Pty. Ltd. (created on Wed Sep 23 16:49:12 2009)