Jump to content
Sign in to follow this  
TheKraut

how to setpitchbank

Recommended Posts

Hello

I am working on a model of the mv22 with mk19 on the ramp without making a new model just with attach to.. and stuff like this. now i dont know how to set a pitch on this object like 25 degrees and the objects name is "mk19" can somebody tell me how i can pitch this?

Share this post


Link to post
Share on other sites

This was asked yasterday http://forums.bistudio.com/showthread.php?t=128407

I think you need to call it after it's you've attached the gunner and setdir his direction.

Be careful as you may have an unexpected problem, too much pitch will cause the unit to exit a static gun, 25 degrees is fine but the angle of the plane will be added to it and when it gets too great the unit bails.

Edited by F2k Sel

Share this post


Link to post
Share on other sites

i already read it. i also tried it but i dont get it.. in which init should i put it and where do i have to put in the objects name "mk19"

yes i know it that the unit bails out. i think 20 should be enough too

Share this post


Link to post
Share on other sites

You can place it in the same line as the attachto command.

[mk19, -25,0] call BIS_fnc_setPitchBank;

Share this post


Link to post
Share on other sites

i appreciate your effort but it dont works :(

by the way. is it possible to make the gunner dont eject if i hit the 90 degrees?

Share this post


Link to post
Share on other sites

You may need an init.sqf file with a bit of code in it if your not using CBA addon or later patches and try placing a function module on the map.

I don't need either but it should work.

init.sqf

waituntil {!isnil "bis_fnc_init"};

The only way I can think of keeping the gunner in the gun would be to read the angle and then freeze him by using unitname enablesimulation false until the angle has reduced enough, but I can't test right now so it may not work.

Share this post


Link to post
Share on other sites

so there is no way to do it in the editor without scripts?

Share this post


Link to post
Share on other sites

Try this then, place a function module and then place the code within a delayed spawn in the same line as the attachto

null=[] spawn {waituntil {!isnil "bis_fnc_init"};[mk19, -25,0] call BIS_fnc_setPitchBank;}

Share this post


Link to post
Share on other sites

yep. works now ;) thanks mate

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×