Home   Help Search Login Register  

Author Topic: Weapon on the floor [ solved ]  (Read 1063 times)

0 Members and 1 Guest are viewing this topic.

Offline UH60MG

  • Members
  • *
Weapon on the floor [ solved ]
« on: 19 Jun 2008, 05:04:38 »
I want an Ak74 to appear on the ground that can be picked up by the player. Is it possible in ArmA and if so how do I it?
« Last Edit: 20 Jun 2008, 04:08:09 by UH60MG »

Offline Trexian

  • Members
  • *
Re: Weapon on the floor
« Reply #1 on: 19 Jun 2008, 05:21:07 »
Do you know where you want it, as in coordinates on the map?  Or just at a place in front of the player at a certain time?
Sic semper tyrannosauro.

Offline UH60MG

  • Members
  • *
Re: Weapon on the floor
« Reply #2 on: 19 Jun 2008, 05:26:29 »
Yes, fixed coordinates.

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: Weapon on the floor
« Reply #3 on: 19 Jun 2008, 05:49:16 »
The following code will place an AK and one magazine in front of the player:

Code: [Select]
_type = "WeaponHolder"
_gun = "AK74"
_ammo = "30Rnd_545x39_AK"
_weapon2 = _type createVehicle [0,0,0]
_weapon2 addweaponCargo [_gun,1]
_weapon2 addmagazinecargo [_ammo,1 ]
_weapon2 setpos (player modelToWorld [0,1,0]);

Simply replace the "(player modelToWorld [0,1,0])" in the setpos line with your exact coordinates.
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...