IPB


Welcome Guest ( Log In | Register )

 Forum Rules ArmedAssault.info Forum Rules
 
Reply to this topicStart new topic
> Object Pickup
Red Star Elite
post Oct 10 2011, 12:02
Post #1


Member
***

Group: Members
Posts: 43
Joined: 6-April 09
From: Milton Keynes, United Kingdom
Member No.: 5,491



Hey guys

Was wondering if there was a script or something that allows the player to pickup lets say, a map and it be shown in the inventory?

Thanks to anyone who can help thumbsup.gif
 
Quote Post
D@V£
post Oct 10 2011, 13:50
Post #2


Gee, I wish we had one of them doomsday machines.
Group Icon

Group: Moderators
Posts: 2,037
Joined: 13-November 06
From: Wales
Member No.: 155



The map's a "weapon", you can add and remove it using the (I think) addweapon and removeweapon commands - if the player doesn't have a map, the map screen will show up blank.

Ie:
CODE
This addweapon "ItemMap";
This removeweapon "ItemMap";


There's also a macguffin map class, if you want a map that doesn't serve any real purpose, but can be used as an objective:

CODE
This addweapon "EvMap";
This removeweapon "EvMap";

(Check here for some more similar classes, bear in mind a lot of the macguffins are ArmA.2 classes, so might not work with just OA, according to SIX they're in configweapons, but they might not have all the resources in place...)

You can check if the player has one of these with the hasweapon command, ie:
CODE
Player hasweapon "EvMap"


Hope this helps! happy.gif


--------------------
The Rules - Nothing too complicated, follow these and we'll have no problems.
Moderation Feedback Thread - Tell everyone how much you hate me love me secretly fear that Mark is watching you while you sleep. secretly wish that Mark is watching you while you sleep.
Site Issues Thread - Complain about site issues here. We might even fix them!
Community Chatter Thread - Furthest Mud-sling gets a free subscription to "JdB Monthly".

QUOTE(Major Mike Shearer)
We can categorically state that we have not released man-eating badgers into the area.
QUOTE(Brace Belden)
A machine gun is like a woman, I don’t understand it, I’m afraid of it, and one day I’ll accidentally be killed by one.
 
Quote Post
Red Star Elite
post Oct 10 2011, 14:07
Post #3


Member
***

Group: Members
Posts: 43
Joined: 6-April 09
From: Milton Keynes, United Kingdom
Member No.: 5,491



So if this map/file etc was placed on a table for example, using one of the scripts you've provided, the player could pick it up and it be shown in the inventory just like any other collectables such as ammo ingame?
 
Quote Post
D@V£
post Oct 10 2011, 15:44
Post #4


Gee, I wish we had one of them doomsday machines.
Group Icon

Group: Moderators
Posts: 2,037
Joined: 13-November 06
From: Wales
Member No.: 155



Yup, it fits in one of the inventory slots. I'm not too sure how to spawn weapons just lying around though... (or if the evidence objects even have models, IIRC in the campaign they're always in boxes or something)


--------------------
The Rules - Nothing too complicated, follow these and we'll have no problems.
Moderation Feedback Thread - Tell everyone how much you hate me love me secretly fear that Mark is watching you while you sleep. secretly wish that Mark is watching you while you sleep.
Site Issues Thread - Complain about site issues here. We might even fix them!
Community Chatter Thread - Furthest Mud-sling gets a free subscription to "JdB Monthly".

QUOTE(Major Mike Shearer)
We can categorically state that we have not released man-eating badgers into the area.
QUOTE(Brace Belden)
A machine gun is like a woman, I don’t understand it, I’m afraid of it, and one day I’ll accidentally be killed by one.
 
Quote Post
Red Star Elite
post Oct 24 2011, 23:52
Post #5


Member
***

Group: Members
Posts: 43
Joined: 6-April 09
From: Milton Keynes, United Kingdom
Member No.: 5,491



Yeah spot on. Cheers once again thumbsup.gif
 
Quote Post

Reply to this topicStart new topic
3 User(s) are reading this topic (3 Guests and 0 Anonymous Users)
0 Members:

 



Lo-Fi Version Time is now: 29th March 2024 - 10:18