A bunch of game engine/python questions.

Game Engine, Players & Web Plug-in, Virtual Reality, support for other engines

Moderators: jesterKing, stiv

Post Reply
bannerboy
Posts: 0
Joined: Sun Sep 05, 2004 1:18 am

A bunch of game engine/python questions.

Post by bannerboy » Tue Dec 28, 2004 4:15 am

I've got a whole pile of game engine/python questions:

1. do partacle systems work in realtime. If so, how?
2. is there any way for several different python scripts on different actuators, and different pbjects communicate?
3. How do you have the python script play an animation, wait till it's done, and then do something else?
4. How are python actuators called, ie are the called multiple times every time sensor input comes in? or are the called once to deal with the sensor input?
5. Every time I turn on shadow calculation for a object, it dissapears in the game engine. is this a bug? or is it me?
6. Do I like C++ too much?

z3r0_d
Posts: 289
Joined: Wed Oct 16, 2002 2:38 am
Contact:

Re: A bunch of game engine/python questions.

Post by z3r0_d » Tue Dec 28, 2004 4:49 am

bannerboy wrote:I've got a whole pile of game engine/python questions:

1. do partacle systems work in realtime. If so, how?
they do not, people have simulated particle systems with slow parents [trails of objects] and with the add object actuator [adding an object with a single halo quad]
bannerboy wrote:2. is there any way for several different python scripts on different actuators, and different pbjects communicate?
what?

python can work with multiple actuators, if you aren't changing options for them it doesn't need to care what type they are
bannerboy wrote:3. How do you have the python script play an animation, wait till it's done, and then do something else?
find how many seconds long the animation is, and setup a timer property

in fact, I don't belive you need python at all, set the property to the amount of time it takes the animation to play, except negative, when you start the animation. Then, using a property greater than 0 sensor start playing your new animation.

[of course, in theory that works, but I haven't tested it]
bannerboy wrote:4. How are python actuators called, ie are the called multiple times every time sensor input comes in? or are the called once to deal with the sensor input?
they are called once, only when pulsed by one or more sensors [so, if you hold a key down the python script will not be called every logic tick unless the true pulse mode is set on the keyboard sensor]
bannerboy wrote:5. Every time I turn on shadow calculation for a object, it dissapears in the game engine. is this a bug? or is it me?
it is you, it isn't shadow calculation

what you should do is create a horizontal flat piece just above the object center. You probably want to give this a black spot texture [with an alpha channel]. Then, select these faces and make them shadow. They should then stay just above and parallel to the ground [or whatever the object is above]
bannerboy wrote:6. Do I like C++ too much?
you're trying blender... this seems a bit irrelevant of a question. If you do like c++ a lot you might want to try ogre3d or the crystal space engine.

... oh, and this is the development forum, questions about how to use blender are much better directed at elysiun.com

KDR_11k
Posts: 2
Joined: Tue Feb 10, 2004 8:06 pm

Post by KDR_11k » Tue Jan 04, 2005 2:27 pm

2. means that if you have multiple Python blocks in your scene how can you get them to modify each other, e.g. Object Bullet calls Object Player's Damage() function or Object Trap calls the die() function of every Object of type Actor it touches.

Post Reply