Game Engine

I m new and getting familiar with blender game engine.
is there any ways to get following done functional ?

  1. Loading dynamic assets from a specific directory as camera moves ahead ? This is to save real time resources and file size. Also I guess this will update loading objects/assets as they are updated / modified .

  2. How can I enable stair climbing and jump in my game? ( this is simple beginner question i guess :wink: )

Any specific samples? or blend files?

Thx

Try just going around the web and finding tutorials, I can point you to some good you tube tutorials:





of course there are more tutorials on the web than these so you will have to look around but thees are a start so have fun

jump amd stair climbing are pretty easy,

Jump logic
if keypress jump-----------and-----------apply force+ set jump to 30
if contacting ground-----/
if jump ==0------------------/

if jump >0--------and--------jump -=1

about stairs, I use a homemade servo motion and a physics shape that tapers near the bottom.

for dynamically loading objects you ca use LibLoad.

edit:
Video and File for jump + stairs
Space = Jump
W = Walk forward

Attachments

Jump_Stairs.blend (487 KB)

  1. Don’t know

  2. The BGE has a special actuator for game character’s that allow them to jump.

As an example, you can set up a keyboard sensor for your character to detect the spacebar, connect the sensor to a motion actuator through an And controller, and set the motion type to Character Motion. The actuator will show a button that says Jump. Click on that and the spacebar will now cause your character to jump (make sure you also set the distance).

The character physics type is pretty inflexible…

that staircase climbing tut was good one. Thx.

However is there any simplistic way to dynamically load part of game scene as camera proceeds ahead and similarly wipe previous part to prevent memory load?

I have made a sample game scene which has 450 MB size in half assets loaded in, I wish if there is way to define a region around camera ( same like LOD) and keep surroundings filled, rest unloaded. That will make game light and smoother.

Thx

However is there any simplistic way to dynamically load part of game scene as camera proceeds ahead and similarly wipe previous part to prevent memory load?

yes there are ways, Libload is one of them

You can call LibLoad and LibFree with a python script to dynamically load and release meshes and scenes from other files.

Use some Near sensors to detect when your camera is coming within range of where your linked objects are. and have the sensor call a python script to load the objects. Expect a slight delay in the game when large files are loaded.