Ich und Luxorion sind grade an einen code der einen realen camera effekt haben soll das problem nun ist wen man schneller rennt oder rechts links flackert sie sehr stark also bei der rotation.
Lua
addEventHandler('onClientRender', root, function()
local matrix = {getCameraMatrix()};
setCameraTarget( localPlayer )
--{x, y, z, faceX, faceY, faceZ}
dxDrawText(('Matrix: %f - %f - %f - %f - %f - %f'):format(matrix[1], matrix[2], matrix[3], matrix[4], matrix[5], matrix[6]), 250, 250);
local myPos = {getPedBonePosition(localPlayer, 6)};
dxDrawText(('Pos: %f - %f - %f'):format(myPos[1], myPos[2], myPos[3]), 250, 270);
local _, _, rot = getElementRotation(localPlayer);
rot = math.rad(rot + 90);
myPos[1] = myPos[1] - 3 * math.cos(rot);
myPos[2] = myPos[2] - 3 * math.sin(rot);
matrix[1] = myPos[1] + 5 * math.cos(rot);
matrix[2] = myPos[2] + 5 * math.sin(rot);
setCameraMatrix(myPos[1], myPos[2], myPos[3], matrix[1], matrix[2], myPos[3] );
end
end);
Alles anzeigen
Code by Luxorion