Ey, i are making a game, but a dont now how to make lifes in it:S
My plan is that the lifes to the blue player are down in right coner and the red player life are down in the left corner.
Someone there can help?

PS: i am a new to BGE and python script.

Hmm… If you haven’t already, I recommend you learn the basics of blender first ie: the interface, panels, tools, etc

Then the basics of the GE

That’s all since you’re new to the BGE.

After that try my tutorial for making life bars in the GE.

Health Bar Tutorial

Health Bar - Extended (Hearts)

Have fun :wink:

Jason Lin

I found out how to make your health bar.
But how do i make so when my player hit the other man some of the life go of?

you can use an empty with a ray (with a short range) or you can use a collision sensor…

ex: Space (attack button) + ray or collison detect property “ennemy” ----- dammage activated

Dont understand.
Can you make an example?
I dunno how to make so it lost life on an other objeckt:S

I cant really right now but I’ll provide you a sample boxing game that I use ray sensor to do dammage. I’ll post it in likein 8 hours since im not on my computer right now

Does’nt matter anymore.
Now i have a new problem:S
I dont now how to make so the objeckt will be deleted when its have 1life. Someone there can help?

Use the end object actuator.


property[Changed, Prop: life] -> Exp[IF sensor(life<=1)] -> End Object


property[Changed, Prop: life] ->
property[Equal, Prop: life, Val: 1) -> AND -> End Object

Jason Lin

Thanks!!! it works:D