Home » MODDING HQ 1.13 » v1.13 Coding Talk » New Attachment System Beta
New Attachment System Beta[message #256358] Fri, 16 July 2010 01:51 Go to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Version 0.61b fixes a CTD and has an updated map editor, read all about it in the readme.

This is the Beta version of NAS. It has been updated to the latest multiplayer revision. It contains all the latest features (and bugs :naughty: )!
The thread for the alpha version can be found here.

In short, what NAS offers:
  • More attachments (or less, if the modder decides to)
  • A new way of determining wether attachments fit or not. However by default all items accept the same attachments as in normal 1.13.
  • More freedom in general with attachments.
  • Almost everything is costumizable, even the position of the slots on the screen. (but you need to edit xml)
  • Many new tooltips concerning attachments.
  • Enemies may have more attachments, and they have only a small chance to drop them (customizable).
  • More possible default attachments for weapons.
  • Attachments can now add and/or remove slots (but merges are still needed to change the caliber of a gun).
  • Big slots are now possible.
  • Mag extenders don't have to be permanent attachments anymore (they still are though, but you can easily change it in the items.xml)
  • You can choose in what attachment system items are available.
  • Lots of little things I can't think of right now.
  • Multishot launchers with separate grenades are possible.
  • Attachment swapping is more intuitive.
  • The option to use attachments balanced for NAS.
NAS will NOT work with the Old Inventory System and it will NOT work in 640*480 mode. This is because there just isn't enough space in those cases. If you try you will get a warning and you will not be able to start the game (but nothing should spontaneously catch fire).
Also, attachments to LBE gear are no longer possible in NAS.

Keep in mind that this is a beta and it is still possible that it causes 40% more elephants to charge your car. It's out here to be tested and it will take some time.

The download can be found here:
ja2_3578_NAS_0.61b

THIS MOD NEEDS TESTING, PLEASE REPORT ANY BUGS YOU FIND

Go ahead and try to break it, cause if it can be broken it needs fixing.

In particular look for:
  • Problems when attaching various different ways.
  • Bugs when turning the system off!
  • General crashes (I'm innocent, I swear! It was the 1.13 team! :pitchfork: ).
  • Problems with merges.
  • Problems when adding or removing slots.
Screenshots from alpha versions (they're still the same anyway, and i'm too lazy to take new ones Very Happy):
http://img715.imageshack.us/img715/1737/screenshot1p.pnghttp://img402.imageshack.us/img402/1428/screenshot2vsg.png
http://img706.imageshack.us/img706/9997/hurray.png
(Trevor Colby has urged me to mention that he does not currently accept any marriage proposals, Stephen, however, will marry the nearest tramp in sight).


The source can be downloaded from the SVN server:
https://81.169.133.124/source/ja2/branches/Wanne/JA2 1.13 MP/

Any other NAS related files (mostly previous versions) can be found here.

[Updated on: Tue, 10 August 2010 22:36] by Moderator

Re: New Attachment System Beta[message #256363] Fri, 16 July 2010 02:24 Go to previous messageGo to next message
Jinxed

 
Messages:240
Registered:October 2008
Location: Land of Skanks and Cottag...
So if this is to be compatible with AIM or IoV they would have to rework their mods to work with it?
Revision 3547? Wow, the current svn available is 3356 and I'm testing something with what I thought was newest 3528... How fast do things get released..? But only available to coders/modders or am I missing something?
Re: New Attachment System Beta[message #256366] Fri, 16 July 2010 03:19 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
Nice! I will test this for sure. But first I gotta find out what all those files in the archive are for. Lots of XMLs... Ah, the new camo faces... What are those .edt files in the NPCDATA folder for?


@Jinxed
We are at revision 3548... Wink

It's no secret and it's not only available to certain people. The locations of the latest developer build is this:

https://81.169.133.124/source/ja2/branches/Wanne/JA2 1.13 MP

That's what RoWa said.

Re: New Attachment System Beta[message #256369] Fri, 16 July 2010 04:55 Go to previous messageGo to next message
Mauser

 
Messages:780
Registered:August 2006
Location: Bavaria - Germany
way cool WarmSteel!

great job on getting this project done and released so far!

once this goes together with AIM and gets balanced somewhat with HAM, this will become one of the major cool features of 1.13 and motivate players anew for some more campaigns in arulco & co!

also, i

☆★GL★☆
Re: New Attachment System Beta[message #256371] Fri, 16 July 2010 05:06 Go to previous messageGo to next message
Kaerar

 
Messages:2050
Registered:January 2003
Location: Australia :D
Hmm now all that's necessary is for this to be integrated with STOMP 1.1 Wink


Re: New Attachment System Beta[message #256396] Fri, 16 July 2010 11:03 Go to previous messageGo to next message
Shadow21

 
Messages:334
Registered:November 2001
Location: on route to San Hermanos
yeah im waiting for that too Razz
Re: New Attachment System Beta[message #256399] Fri, 16 July 2010 11:56 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
silversurfer
Nice! I will test this for sure. But first I gotta find out what all those files in the archive are for. Lots of XMLs... Ah, the new camo faces... What are those .edt files in the NPCDATA folder for?
Those files are just for new features in the MP version.
There are no new NAS files.
Re: New Attachment System Beta[message #256411] Fri, 16 July 2010 14:21 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
Warmsteel, can you please add the ini settings to the first post? I doubt that anyone wants to copy the included Ja2_Options.ini over their installation as that resets every setting they changed so far. Also it would set certain settings to values that you don't want to play with, like "GAME_PROGRESS_MINIMUM = 90". Wink

I was looking at the ini to find out which settings are new in this developer build and these are my findings:

In section [Tactical Interface Settings]:
SHOW_TACTICAL_FACE_GEAR = TRUE

SHOW_TACTICAL_FACE_ICONS = TRUE

TACTICAL_FACE_ICON_STYLE = 0

SHOW_CAMOUFLAGE_FACES = TRUE


In section [Tactical Gameplay Settings]:
CAN_JUMP_THROUGH_WINDOWS = TRUE

CAN_CLIMB_ON_WALLS = TRUE

INDIVIDUAL_HIDDEN_PERSON_NAMES = TRUE

INDIVIDUAL_ENEMY_NAMES = FALSE

INDIVIDUAL_ENEMY_RANK = TRUE

INDIVIDUAL_CIVILIAN_NAMES = TRUE


In section [Tactical Cover System Settings]:
COVER_SYSTEM_STEALTH_TRAIT_COVER_VALUE = 15

was replaced by
COVER_SYSTEM_STEALTH_TRAIT_VALUE = 15

Cover system values have changed a lot so everybody better double checks them.


In section [Item Property Settings]:
;------------------------------------------------------------------------------------------------------------------------------
; Use the New Attachment System?
;------------------------------------------------------------------------------------------------------------------------------

USE_NEW_ATTACHMENT_SYSTEM = TRUE

;------------------------------------------------------------------------------------------------------------------------------
; The percentage chance each attachment will have to drop with the item if an enemy dies.	0 - 100%
; Default attachments and inseperable attachments will not be removed.
; Higher than 20% is not recommended unless you change MAX_ENEMY_ATTACHMENTS.
;------------------------------------------------------------------------------------------------------------------------------

;ATTACHMENT_DROP_RATE = 10

;------------------------------------------------------------------------------------------------------------------------------
; The maximum amount of attachments NPC's can get on their gun when they get random equipment.
; They will usually get less attachments than this value because of randomness.
; min - 2  max - 30
;------------------------------------------------------------------------------------------------------------------------------

;MAX_ENEMY_ATTACHMENTS = 6

This is for NAS but why are two options inactive? Are these values the default?


edit: Btw. it can't load savegames from the 3356 SVN exe.
edit2: This is not your fault. Even the default 3548 exe can't load savegames from 3356 exe. Too bad. Sad

[Updated on: Fri, 16 July 2010 15:19] by Moderator


Re: New Attachment System Beta[message #256415] Fri, 16 July 2010 15:23 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Quote:
Btw. it can't load savegames from the 3356 SVN exe.

too bad then Smile

Quote:
This is for NAS but why are two options inactive?

... oops?
They will just be reverted to the default, yes.
You can just uncomment them for them to work.
I'll change these things for the next build Smile

Quote:
Also it would set certain settings to values that you don't want to play with, like "GAME_PROGRESS_MINIMUM = 90"

double oops Smile
Re: New Attachment System Beta[message #256416] Fri, 16 July 2010 15:31 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1540
Registered:March 2009
Location: Broadwurschd-City
I always pimp my ini anew and would like

a) to rename the old ini
b) a button in editor: take settings from old ini
Re: New Attachment System Beta[message #256431] Fri, 16 July 2010 16:53 Go to previous messageGo to next message
Minty

 
Messages:115
Registered:July 2009
Location: UK
Meh. It's kind of a ritual for me, going through new .ini files by hand, tweaking them as I see fit. Besides, it gives one a better idea of any new settings that've come up since the last revision. Having it automated would leave me out of the loop somewhat.

I'm not saying I'm against having a button like you requested, Gorro. Just that I'd have no use for it. But, I like getting my hands dirty in Notepad ++. Wink
Re: New Attachment System Beta[message #256433] Fri, 16 July 2010 17:06 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1540
Registered:March 2009
Location: Broadwurschd-City
1) reload the old values
2) make you fingers dirty

I sometimes forget why I made this or that

call me Gasket
Re: New Attachment System Beta[message #256434] Fri, 16 July 2010 17:09 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
Ok, I played around a bit and found no problems so far.

I tested:
  • attach at appropriate slot - gets attached
  • attach at wrong slot - displays error message
  • attach stack of objects to slot - one attachment gets attached, the rest stays at hand cursor
  • attach incompatible items together (like ISM-V-IR and scope - displays error message
  • remove attachment - gets removed
  • attach grenade without launcher - displays error message
  • simulate that someone forgot to assign a slot to an attachment (removed attachment 1012 "AR Suppressor" from AttachmentSlotAssign.xml) - displays error message

    Btw. why did you define this three times in the XML? What do you need three muzzle slots for? Is that for future modding so that you can attach more items to the muzzle? Something like a super suppressor which is build from three parts? Very Happy :
    http://img143.imageshack.us/img143/2598/supersuppressor.jpg

Screen shots:

Fully pimped M16:
http://img191.imageshack.us/img191/8660/screen030d.th.jpg


@Gorro

There are tools to compare text files. Maybe you would like one of these?
I use the Total Commander which also is my preferred file manager.

The compare window looks like this:
http://img695.imageshack.us/img695/6909/inicompare.th.jpg
Left side=My Ini, Right Side NAS Ini, Red colour is for differences, to change/copy something simply edit inside the window.

Re: New Attachment System Beta[message #256435] Fri, 16 July 2010 17:19 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1540
Registered:March 2009
Location: Broadwurschd-City
still the old ini isn't renamed automatically (and the ini should be re...)

do you have download for the sw or ain't it free?
Re: New Attachment System Beta[message #256436] Fri, 16 July 2010 17:23 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Quote:
Btw. why did you define this three times in the XML? What do you need three muzzle slots for?

Each weapon can only have one of these slots. (well, they can have 500, but they would be posted over each other, so it would be pointless).
It is to simulate that some weapons can attach only a few attachments, and others may be able to attach more.
Re: New Attachment System Beta[message #256440] Fri, 16 July 2010 17:27 Go to previous messageGo to next message
Minty

 
Messages:115
Registered:July 2009
Location: UK
The three muzzle slots are for the different kinds of muzzles. Pistol, AR, and large calibre weapon, I think.

I've not had a chance to properly look through the XMLs yet, but it's how I'd do it. I'd have two muzzles defined for each size of weapon. One that can take a flash-suppressor only, and one that can take both a flash and sound suppressor (Not at the same time, obviously).

So then, all I'd need to do for a new weapon is decide if I want to allow sound suppressors or not, and add the relevant attachment-slot to the correct XML.

Of course, my own mod, which is shaping up ok, is bringing Possum's DBB mod into line with NAS.. So I've a cubic bucketload of attachments to play with. Hell, AKs even get their own suppressor, and that's before we start talking about muzzle-launched rifle-grenades. Then there's the joy that will be RG-6 and Milkor drum-fed GLs taking loose 40mm grenades, instead of the current cludgy "grenade clips"

Edit: Ninja'd by Warmsteel.. Very Happy

[Updated on: Fri, 16 July 2010 17:28] by Moderator

Re: New Attachment System Beta[message #256443] Fri, 16 July 2010 17:40 Go to previous messageGo to next message
Kaerar

 
Messages:2050
Registered:January 2003
Location: Australia :D
@Silversurfer - gotta love that description on the M16 to go with all the mods Wink


Re: New Attachment System Beta[message #256444] Fri, 16 July 2010 17:41 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
@Gorro

It's a shareware but since I use it everyday I decided to give the good man some well deserved payment. Here's the link:

http://www.ghisler.com/


@Warmsteel

Looks like I need the source code to understand what you are doing there. Some things just won't become clear to me. Very Happy

Poor smeagol, if he wants to implement AIM he will have a lot to consider. Same applies to HLTV and IoV...


edit: @Kaerar

Yeah, from Vietnam we know that we need super-pimped weapons! :diabolical:

[Updated on: Fri, 16 July 2010 17:43] by Moderator


Re: New Attachment System Beta[message #256445] Fri, 16 July 2010 17:45 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Minty
Of course, my own mod, which is shaping up ok, is bringing Possum's DBB mod into line with NAS.. So I've a cubic bucketload of attachments to play with. Hell, AKs even get their own suppressor, and that's before we start talking about muzzle-launched rifle-grenades. Then there's the joy that will be RG-6 and Milkor drum-fed GLs taking loose 40mm grenades, instead of the current cludgy "grenade clips"
Hurhur, you're fucked. The number of attachments slots you need to define grow exponentially the more attachments there are possible (as more combinations become possible) :diabolical:
Same was true for the old system though
Minty
Edit: Ninja'd by Warmsteel.. Very Happy

:naughty:
Re: New Attachment System Beta[message #256447] Fri, 16 July 2010 18:12 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
WarmSteel

More possible default attachments for weapons.


Where do you define default attachments? Do you still take it from Items.xml? How do you define multiple default attachments?

Re: New Attachment System Beta[message #256449] Fri, 16 July 2010 18:13 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
defaultattachment1
defaultattachment2

up to 10, for now.

EDIT:
I will make examples for this when I releases an items.xml. But there are too few changes for it now.

[Updated on: Fri, 16 July 2010 18:14] by Moderator

Re: New Attachment System Beta[message #256451] Fri, 16 July 2010 18:34 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1540
Registered:March 2009
Location: Broadwurschd-City
Scope
the most likley took shelder under the rock they crawled out from under


:et5:
Re: New Attachment System Beta[message #256452] Fri, 16 July 2010 18:34 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
WarmSteel
defaultattachment1
defaultattachment2

up to 10, for now.

EDIT:
I will make examples for this when I releases an items.xml. But there are too few changes for it now.


So that means that you don't touch to leave the old system as it is, right? Looks like much work for you to define new defaults. Razz

Re: New Attachment System Beta[message #256453] Fri, 16 July 2010 18:36 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
DefaultAttachment is just the first one now, so the old XML's can still be used.
No need to screw those up.
Re: New Attachment System Beta[message #256474] Fri, 16 July 2010 21:31 Go to previous messageGo to next message
Wil473

 
Messages:2861
Registered:September 2004
Location: Canada
Just when I though it was safe to release a new (savegame and UC NAS Test mod breaking) version of the UC-1.13 Hybrid...

I spent a few minutes with the Beta release available earlier this morning. So far good news:

1) the UC NAS Test mod works fine with it, even better actually with the newer code base (missing garrison bug after underground victory bug is resolved). Only some assembly was required to assemble a new Data folder to override the Hybrid (not yet released) version of the mod, and some quick edits to the new .INI file.

2) I could not replicate the random CTD's that occurred in the last Alpha test of NAS when NAS was turned off in the .INI file. Of course that was only a few minutes of trying to break it, but the first impressions of the NAS Beta, through the lens of experience with the NAS Alpha tests, is very promising.

EDIT: thought I should add that with the Alpha (default Vanilla campaign) it crashed 2/3 of the time when moving throwing knives around the inventory.

[Updated on: Fri, 16 July 2010 21:34] by Moderator



Re: New Attachment System Beta[message #256475] Fri, 16 July 2010 21:33 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
There was one bug concerning trying to attach to LBE that was still there.
But fixed it when updating ^^
Re: New Attachment System Beta[message #256476] Fri, 16 July 2010 21:33 Go to previous messageGo to next message
Nickfighter

 
Messages:120
Registered:December 2007
Location: Poland
Kaerar
Hmm now all that's necessary is for this to be integrated with STOMP 1.1 Wink

Oh yeah.
Re: New Attachment System Beta[message #256490] Fri, 16 July 2010 22:59 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
Warmsteel, would you please give me your source code?
I would like to merge this with STOMP 1.1 source code for personal use. This would allow me to better test both and start a new campaign (for the 100+ time so far...).

Re: New Attachment System Beta[message #256493] Fri, 16 July 2010 23:08 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Have patience, young padawan.
Re: New Attachment System Beta[message #256495] Fri, 16 July 2010 23:14 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
No, I want to join the dark side! :vader:

If I can't get the source code I'm going to stick with my own minimod and continue to play with that. I'm half way through the game and don't want to restart again for no reason only to restart again in some weeks when somebody else merges STOMP with NAS. I already restarted for NAS alpha. It's no fun if the savegames get broken all the time. Sad

Re: New Attachment System Beta[message #256496] Fri, 16 July 2010 23:16 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Well it will only be a few days, and there have been a few small bugs popping up so I want to get those out first.
Re: New Attachment System Beta[message #256519] Sat, 17 July 2010 01:13 Go to previous messageGo to next message
Jinxed

 
Messages:240
Registered:October 2008
Location: Land of Skanks and Cottag...
What's a few days when this game has been out for over 10 years eh? Razz
Re: New Attachment System Beta[message #256523] Sat, 17 July 2010 04:14 Go to previous messageGo to next message
silversurfer

 
Messages:2543
Registered:May 2009
To me it means a lot because I'm on holiday at the moment and have time to program and play. Smile

Re: New Attachment System Beta[message #256530] Sat, 17 July 2010 06:39 Go to previous messageGo to next message
Minty

 
Messages:115
Registered:July 2009
Location: UK
Okay, may as well ask this here as anywhere.. What characters do I use to put comments in XML files? Are comments anything after "//", or are they ?

I'm asking, as I want to comment the various number-based NAS XMLs as I work on them so I know what's what. Mainly for ease of reference if I happen to take a couple days off, and want to easily remember where I got up to..

Edit: I'm an idiot, and forgot to rootle through other XML files to check..

is a comment, for anyone else who may be curious. Don't mind me, gents. Smile

[Updated on: Sat, 17 July 2010 07:17] by Moderator

Re: New Attachment System Beta[message #256547] Sat, 17 July 2010 12:31 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
In fact, mostly anything that is not between 2 valid tags is ignored ^^
Though it would make a bit of a mess...
Re: New Attachment System Beta[message #256742] Sun, 18 July 2010 19:09 Go to previous messageGo to next message
Wil473

 
Messages:2861
Registered:September 2004
Location: Canada
Warmsteel, I noticed the Bobby Rays website pop-ups are displaying multiple occurrences of attachments when the attachment can be fitted to more than one attachment slot on the gun. Consequence of being allowed to multiple slots on the same gun for the same attachments. I'm sort of guilty for causing this one, as I was the one who pushed for allowing an attachment to have multiple possible attachment points on a gun.*** Mind you later on, the outgrowth of the above, having multiples of the same attachment being allowed on the same gun, is now a feature (one I have yet to exploit). I don't remember if this was brought up in the last thread. Any plans of having the list of possible attachments checked for repeats before being displayed in the popup item hints?


*** Background from the Alpha thread: This feature is a great time saver when producing XML's as you don't have to figure out attachment slots for each case an attachment may repeat on a particular gun (leading to more attachment slots), but instead can define universal "building block" attachment slots (ie. side RIS, bottom quad RIS, front top quad RIS...). This sort of is reflected in reality, especially with RIS systems. Initially I ended up defining less attachment slots than Warmsteel's original to achieve similar results. Basically it allows an attachment slot to be reused more often on different guns with less planning and worry about conflicts.

[Updated on: Sun, 18 July 2010 19:15] by Moderator



Re: New Attachment System Beta[message #256745] Sun, 18 July 2010 19:18 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
I'll take a look if I can filter out the double attachments.
Re: New Attachment System Beta[message #256755] Sun, 18 July 2010 21:29 Go to previous messageGo to next message
Minty

 
Messages:115
Registered:July 2009
Location: UK
I just wanted to post for any modders out there, to help them get the most from NAS and it's configurable slots..
	
		102
		
		1030
		20
		
		51
		
		103
	


The above code is from my AttachmentSlotAssign.xml. In my reworking of Possum's DBB Mod, a weapon with no attachments will only have one scope-slot visible. Attaching various scopes will add additional slots for use. In this case, attaching an ACOG 3.5x scope will add a slot above it for reflex sights, and a slot behind it for certain night vision devices.

You can use the tag as many times as you wish per attachment, or not at all. And each additional entry is individual to that attachment and that slot. So, for example, you can have a LAM add one (or more) slots only when attached to a certain slot.

Also, the reverse is true with the tag. You can have extra-long scopes remove top-rail slots from the weapon, restricting extra attachments, or whatever strikes your fancy.

In the above code, note that the lines between are comments, and aren't necessary in the XML, but I like to comment my code for ease of reference.

As I said in another thread, with NAS, the possibilities are endless, only limited by the modder's imagination. Smile
Re: New Attachment System Beta[message #256760] Sun, 18 July 2010 22:06 Go to previous messageGo to next message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Thank you for explaining these tags.
Might type out a little readme for modders to shed some light on all the tags that can be used. (I kinda forgot myself... need to look at the xml reader Wink )
Re: New Attachment System Beta[message #256763] Sun, 18 July 2010 22:19 Go to previous messageGo to previous message
Faithless

 
Messages:442
Registered:October 2009
Location: The safe end of the barre...
Wil, uploaded a exe with a fix for the duplicate attachments. Only had to add one line Smile
Check out if it works correctly, I've only tried it with one item.
Previous Topic: Experimental Project 7
Next Topic: Code Snippets
Goto Forum:
  


Current Time: Thu Jun 20 09:16:42 EEST 2019

Total time taken to generate the page: 0.03297 seconds