Home » PLAYER'S HQ 1.13 » JA2 Complete Mods & Sequels » UC/DL 1.13 & AFS » Help me decode Arulco Folding Stock attachment system
Help me decode Arulco Folding Stock attachment system[message #357248] Wed, 17 April 2019 01:39 Go to next message
CareBear

 
Messages:117
Registered:April 2016
So each item like weapons have code similar to this:

<AvailableAttachmentPoint>1261568</AvailableAttachmentPoint>

But the only file that reference this value, is in tabledata/lookup/attachmentpoint.xml, and there's no data tied to it, beside name, it looks like this:

<AttachmentPoint>
		<id>1261568</id>
		<name>S - HV/RG/KCB</name>
	</AttachmentPoint>

I see that by changing this value i can change available weapon attachments, but what defines what constitutes as these attachments? I would like to add or remove attachments per these slots, but i have no idea how to do that with AFS system.
Re: Help me decode Arulco Folding Stock attachment system[message #357643 is a reply to message #357248] Fri, 12 July 2019 16:00 Go to previous message
BulletSix

 
Messages:47
Registered:October 2005
Location: Germany
i have been working on the same "problem"

i found a way to add the ability to allow "Rod&Spring" for a gun. I`ll try to give an overview what i did, maybe it helps big grin

first i found a file "AttachmentPoint.xml" in "Lookup" there is an entry for the rod&Spring.

<AttachmentPoint>
<id>100663296</id>
<name>Rod&amp;Spring</name>
</AttachmentPoint>

And i thought it follows the same principle as with the molle/LBE-system: each slot has a value and adding the values gives you the according slots to work with (e.g. slot1 value 1; slot2 value 2; setting Available slots to 1 gives you slot 1 only, setting it to 2 gives you slor 2 only; setting it to 3 gives you both etc.)

so i tried to add the number to a <AvailableAttachmentPoint>XXX</AvailableAttachmentPoint> (XXX+[id-number for R&S in AttachmentPoint.xml]=new number) i the items.xml

this worked somewhat: i can add rod&spring to the gun but also add a trigger group suprised

however there is an entry in AttachmentPoint.xml for <name>Trigger - Add 3 Round Burst</name>
<AttachmentPoint>
<id>67108864</id>
<name>Trigger - Add 3 Round Burst</name>
</AttachmentPoint>

now i tried to subtract the "trigger-group" from the "rod&spring"
 100663296
-67108864
------------
33554432
and added the result to an entry <AvailableAttachmentPoint>XXX</AvailableAttachmentPoint> i got the possibility to add a Rod&Spring to the gun without being able to add a triggerGroup, too (and actually adding the item changes the stats as it should).
the same works if you add
<AvailableAttachmentPoint>33554432</AvailableAttachmentPoint>
as a new line to the gun in items.xml

But how exactly this works and how why i had to "substract the triggergroup" ... suprised suprised

propably the areay of th gun, where the attachment is possible is defined somewhere else? Or the placement of the attachment (muzzle, under-barrel, sight, internal, etc.) is already defined with the number ....

hopefully wil473 will find the time to give a rough description, how this works happy

Previous Topic: Help with Urban Chaos - Subway
Next Topic: Arulco Folding Stock FAQ - Read this before asking questions please
Goto Forum:
  


Current Time: Mon Aug 19 23:49:45 EEST 2019

Total time taken to generate the page: 0.01456 seconds