Commit 27734789 authored by Mezilsa's avatar Mezilsa
Browse files

Formatierung

parent 28786b1f
......@@ -23,27 +23,26 @@ player addEventHandler ["Fired", {
}];
vehicle player addEventHandler ["Fired", {
_unit = _this select 0;
_shell = _this select 6;
_velocity = velocity _shell;
_velocity params ["_x", "_y", "_z"];
_unit = _this select 0;
_shell = _this select 6;
_velocity = velocity _shell;
_velocity params ["_x", "_y", "_z"];
_velocityBlank = sqrt (_x^2 +_y^2);
_direction = direction _shell;
_hintstr = ("Die Kugel fliegt mit "+ str _velocityBlank +" m/s in Richtung "+str _direction) +" und mit "+ str _z +" m/s nach oben";;
_velocityBlank = sqrt (_x^2 +_y^2);
_direction = direction _shell;
_hintstr = ("Die Kugel fliegt mit "+ str _velocityBlank +" m/s in Richtung "+str _direction) +" und mit "+ str _z +" m/s nach oben";;
_t = _z/9.81;
_tGes = _t*2;
_t = _z/9.81;
_tGes = _t*2;
_deltaX = (sin _direction) * _velocityBlank *_tGes;
_deltaY = (cos _direction) * _velocityBlank *_tGes;
_distance = sqrt (_deltaX^2 + _deltaY^2);
_deltaX = (sin _direction) * _velocityBlank *_tGes;
_deltaY = (cos _direction) * _velocityBlank *_tGes;
_distance = sqrt (_deltaX^2 + _deltaY^2);
_targetPos = _unit getPos [_direction ,_distance];
_targetPos = _unit getPos [_direction ,_distance];
_hintStr = "GeschwindigkeitX = "+str _velocityBlank +" Geschwindigkeit Z = "+str _z + "Richtung: "
+ str _direction + "Delta X " + str _deltaX + " DeltaY "+ str _deltaY + "Entfernung von " + str _distance;
_hintStr = "GeschwindigkeitX = "+str _velocityBlank +" Geschwindigkeit Z = "+str _z + "Richtung: " + str _direction + " Delta X " + str _deltaX + " DeltaY "+ str _deltaY + "Entfernung von " + str _distance;
hint _hintStr;
_targetPos;
}];
hint _hintStr;
_targetPos;
}];
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment