RedStorm 0 Posted May 4, 2003 How would one go about placing weapons on either the ground or a table. I know this has been posted a while back by Suma or another OFP developer, but I can't find the post. I know about the weaponcreate command which "finds" the table and then places the weapon on that table, but I can only place one weapon on a table this way. I remember that it had something to do with placing a marker? Could someone shed a little light on this? Thanks in advance. Share this post Link to post Share on other sites
lonesoldier 0 Posted May 4, 2003 How do i do the one you said that "finds" the table? Share this post Link to post Share on other sites
Polishdude 0 Posted May 4, 2003 Search: Weapons on ground. There is a script for it. To get it on table you just setpos. Or just ask Red to help you, he created the script! Share this post Link to post Share on other sites
RedStorm 0 Posted May 4, 2003 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (Polishdude @ 04 May 2003,12:40)</td></tr><tr><td id="QUOTE">Search: Weapons on ground. There is a script for it. To get it on table you just setpos. Or just ask Red to help you, he created the script! <span id='postcolor'> Perhaps this is taking it a bit too far, but is there a way to change the weapons "azimut" (heading), so I can place them about all facing different directions? PS. Thanks for the PM Polishdude! Share this post Link to post Share on other sites
Polishdude 0 Posted May 4, 2003 You Welcome! The azimut, create the script then if you name the weapon, put this in the script i think this setazimut 45 ask the Red guy agian lol. something like that or just turn that wheel of  fortune around, make sure you name the weapon in the script!!!!   Good luck! Share this post Link to post Share on other sites
RED 0 Posted May 4, 2003 If you are using that script use : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _table = _this select 0 _weapon = _this select 1 _ammo = _this select 2 _height = _this select 3 _dir = _this select 4 weapon = "WeaponHolder" createVehicle [getpos _table select 0,getpos _table select 1,(getpos _table select 2) + _height] weapon addweaponCargo [_weapon,1] weapon addMagazineCargo [_ammo,4] weapon setpos [getpos _table select 0,getpos _table select 1,_height] weapon setdir _dir <span id='postcolor'> Exec the script with: </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">[nameofgamlogic, weaponname, ammoname, heightoffground, range from 0 - 360] exec "weapon.sqs" <span id='postcolor'> RED Share this post Link to post Share on other sites
RedStorm 0 Posted May 4, 2003 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (RED @ 04 May 2003,15:00)</td></tr><tr><td id="QUOTE">If you are using that script use : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _table = _this select 0 _weapon = _this select 1 _ammo = _this select 2 _height = _this select 3 _dir = _this select 4 weapon = "WeaponHolder" createVehicle [getpos _table select 0,getpos _table select 1,(getpos _table select 2) + _height] weapon addweaponCargo [_weapon,1] weapon addMagazineCargo [_ammo,4] weapon setpos [getpos _table select 0,getpos _table select 1,_height] weapon setdir _dir <span id='postcolor'> Exec the script with: </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">[nameofgamlogic, weaponname, ammoname, heightoffground, range from 0 - 360] exec "weapon.sqs" <span id='postcolor'> RED<span id='postcolor'> That's exactly the script I'm using! Thanks all for helping me! By the way, that's a great script Red, thanks a lot for that! Share this post Link to post Share on other sites
RedStorm 0 Posted May 5, 2003 Ok, it works like a charm and I'm very happy with the results. Now I want to take it a step further. How can I have weapons stand in an upright position, slightly leaning to the side, as if leaning against a table? So the butt end rests on the ground and the weapon is upright against the table, slightly leaning towards one end. Would this be possible to do, or am I taking it a bit too far here? Share this post Link to post Share on other sites
RED 0 Posted May 5, 2003 I don't think you will be able to do this as there is no setpitch command. RED Share this post Link to post Share on other sites
elendil004 0 Posted May 5, 2003 You could, in theroy, make a model of a gun that is set up as tho leaning against the table, and just have it not used for actual combat perhaps. Share this post Link to post Share on other sites
Polishdude 0 Posted May 5, 2003 Maybe you have to name a weapon? Share this post Link to post Share on other sites