Hallo

ich Programmiere dieses Spiel und ich hätte eine kleine frage.
Dieser Code ist die Schwerkraft von meinem Spieler und zwischendurch springt der sehr hoch in die luft und fällt nicht mehr runter.(wie im Bild)
Habe ich einen Fehler im Code?

and now i will try it to translate it into english

I' m programming this game and i have a little question.
This code is for the gravitation in my game and somtimes the player jumps in the air and doesn't fall down (you can see it in the picture). the code is here. Where is the error???



http://www.bilder-hochladen.net/files/bq5f-3-jpg.html
für vollansicht/ for the complete picture

Html:
function schwerkraft() 
{
	var abstand;
	
	
	while(1)
	{
		abstand = c_trace(my.x,vector(my.x,my.y,my.z - 1000),IGNORE_ME + USE_BOX + IGNORE_PASSABLE + IGNORE_PUSH); // misst 1000 Quant unter dem objekt
		
		my.z = my.z - abstand+0.1; // platziert das objekt auf die gemessene höhe + 0.1 
		if(abstand > 150 )//Fallschaden
		{
			my.skill1 -= 100;
		}
		
		wait(1);
	}	
	
}


MGF

Patrick

wir haben uns entschlossn, so eine art tagebuch zu moachen wo wir einmal die woche den fortschritt und das geplante für die nächste woche reinschreiben ab montag nächste woche werden wir beginnen.

we decided, that we we will make a kind of diary where we will write every week the progress of our project and what we will do the next week, we will start on monday

Quote:
cant read german, but i do have to say, that is a manly looking elf.


i it is the perspective and the export from blender, looks the orginal in blender
http://www.bilder-hochladen.net/files/bq5f-5-jpg.html

MGF
Weisl


Last edited by weisl12; 08/24/09 20:19.