Home » PLAYER'S HQ 1.13 » v1.13 General Gameplay Talk » Source Code Explained
Source Code Explained[message #347015] Thu, 22 September 2016 04:11 Go to next message
Bobby R.

 
Messages:27
Registered:September 2016
Hi guys.

I would like to know if the community already created a documentation for the ja2 source code?
The c files don't seem to have any content regarding the number of characters the game can distinguish
after my first "scan". (Ca. 200+?) Instead of replacing an old character to get a new one, you just ad one.

Does anybody knows where the game is regulating this?
I grinded the forum but could just find posts regarding face and audio file replacements.

Thanks for your time and have a great day.

Re: Source Code Explained[message #347017 is a reply to message #347015] Thu, 22 September 2016 07:39 Go to previous messageGo to next message
Bobby R.

 
Messages:27
Registered:September 2016
I found this list here but i am not sure if its an info list or the global setting for how man characters the game knows?
/Data/data.slf ENGNPCDATA.TXT

-- DATALIB98 -- Data Library Maintenance Utility -- v2 --
E:\Ja2\Data
Verbose listing of library NPCDATA.SLF
Path offset from default directory is: NPCDATA\
Library version: 2.0
Library entries are sorted
Number of entries present: 315
Number of entries in use: 315

Flg Filename Size Date Time Offset
=== =============================== ========== ========== ======== ==========
000 NPC 1600 03-26-1999 11:02:40 532
057 EDT 15360 03-26-1999 11:00:48 2132
057 NPC 1600 03-26-1999 11:02:40 17492
058 EDT 10560 03-26-1999 11:00:48 19092
.....
190 NPC 1600 03-26-1999 11:03:12 1481812
191 NPC 1600 03-26-1999 11:03:12 1483412
192 NPC 1600 03-26-1999 11:03:12 1485012
193 NPC 1600 03-26-1999 11:03:12 1486612
194 NPC 1600 03-26-1999 11:03:14 1488212
195 NPC 1600 03-26-1999 11:03:14 1489812
196 NPC 1600 03-26-1999 11:03:14 1491412
56 EDT 52795 03-19-1998 13:18:22 1493012
66 EDT 14400 03-18-1998 11:40:48 1545807
67 EDT 14400 03-18-1998 11:40:48 1560207
97 EDT 14400 03-18-1998 11:40:50 1574607
98 EDT 14400 03-18-1998 11:40:50 1589007
A2 EDT 1600 03-17-1999 17:52:46 1603407
A2 NPC 1600 03-17-1999 17:52:46 1605007
B13 EDT 1600 03-17-1999 17:52:46 1606607
B13 NPC 1600 03-17-1999 17:52:46 1608207
B2 EDT 1600 03-17-1999 17:52:48 1609807
B2 NPC 1600 03-17-1999 17:52:48 1611407
C13 EDT 2560 03-17-1999 17:52:48 1613007
C13 NPC 1600 03-17-1999 17:52:50 1615567
C5 EDT 960 03-17-1999 17:52:48 1617167
C5 NPC 1600 03-17-1999 17:52:48 1618127
C6 EDT 1280 03-17-1999 17:52:48 1619727
C6 NPC 1600 03-17-1999 17:52:48 1621007
CIV00 EDT 4800 03-17-1999 17:52:34 1622607
CIV01 EDT 4800 03-17-1999 17:52:34 1627407
CIV02 EDT 4800 03-17-1999 17:52:34 1632207
.....
CIV38 EDT 320 03-17-1999 17:52:46 1796047
CIV39 EDT 3200 03-17-1999 17:52:46 1796367
D13 EDT 3200 03-17-1999 17:52:50 1799567
D13 NPC 1600 03-17-1999 17:52:50 1802767
D5 EDT 960 03-17-1999 17:52:50 1804367
D5 NPC 1600 03-17-1999 17:52:50 1805327
D_057 EDT 16800 03-26-1999 11:01:20 1806927
D_058 EDT 16800 03-26-1999 11:01:20 1823727
D_059 EDT 16800 03-26-1999 11:01:22 1840527
D_060 EDT 16800 03-26-1999 11:01:22 1857327
F10 NPC 1600 03-17-1999 17:52:52 1874127
F8 EDT 1600 03-17-1999 17:52:50 1875727
F8 NPC 1600 03-17-1999 17:52:50 1877327
F9 EDT 1600 03-17-1999 17:52:50 1878927
F9 NPC 1600 03-17-1999 17:52:52 1880527
G8 EDT 1600 03-17-1999 17:52:52 1882127
G8 NPC 1600 03-17-1999 17:52:52 1883727
G9 EDT 1600 03-17-1999 17:52:52 1885327
G9 NPC 1600 03-17-1999 17:52:52 1886927
H1 EDT 1600 03-17-1999 17:52:52 1888527
H1 NPC 1600 03-17-1999 17:52:52 1890127
H13 EDT 1600 03-17-1999 17:52:54 1891727
H13 NPC 1600 03-17-1999 17:52:54 1893327
H2 EDT 1600 03-17-1999 17:52:54 1894927
H2 NPC 1600 03-17-1999 17:52:54 1896527
H3 EDT 1600 03-17-1999 17:52:54 1898127
H3 NPC 1600 03-17-1999 17:52:54 1899727
I14 EDT 1600 03-17-1999 17:52:54 1901327
I14 NPC 1600 03-17-1999 17:52:54 1902927
L11 EDT 1600 03-17-1999 17:52:56 1904527
L11 NPC 1600 03-17-1999 17:52:56 1906127
L12 EDT 1600 03-17-1999 17:52:56 1907727
L12 NPC 1600 03-17-1999 17:52:56 1909327
MINERS NPC 1600 03-17-1999 17:52:46 1910927
==========
Total length data: 1911995


This is just an excerpt for space reasons.
Re: Source Code Explained[message #347025 is a reply to message #347017] Fri, 23 September 2016 02:23 Go to previous messageGo to next message
Bobby R.

 
Messages:27
Registered:September 2016
200 Views in 24h and no post yet? Bottopia? ;) just kidding...

So nobody has any idea where to find the game settings that regulates how many NPC's the game knows / distingueshes?
AAhhhhrrrggghhh suprised , ok i guess i see if i can get in contact with the original programmers to find that out because i can't find anything on the internet about that or i am not using the right words for the search. I will post what i will find out.

cool
Re: Source Code Explained[message #347028 is a reply to message #347025] Fri, 23 September 2016 11:21 Go to previous messageGo to next message
tais

 
Messages:796
Registered:February 2008
Location: NL
How about this
http://thepit.ja-galaxy-forum.com/index.php?t=msg&th=21656&prevloaded=1&&start=0



IRC, pretty much the place to be!

☆☆M☆☆
Re: Source Code Explained[message #347029 is a reply to message #347028] Fri, 23 September 2016 12:04 Go to previous messageGo to next message
DepressivesBrot

 
Messages:3743
Registered:July 2009
I'm not even sure what you're actually talking about anyway. Proper and fully fleshed out NPCs or those random fluff civvies? If there's no explicit limit defined anywhere, then the data type that stores indices gives us an implicit limit, which is 255 for all-up 'people'.



Need help or just want to kill some time? Visit the Bear's Pit IRC ChannelNote: Say 'Hi' and be patient, it may take a few minutes for someone to react.
Latest 1.13 Builds
My Inbox is for IMPORTANT stuff, NOT random queries about the game.


Re: Source Code Explained[message #347030 is a reply to message #347025] Fri, 23 September 2016 12:05 Go to previous messageGo to next message
Enneagon

 
Messages:42
Registered:July 2016
Location: Latvia
My guess would be that probably nobody clearly understands what your true question is, because what you present so far seems somewhat weird or incredibly misguided at very least, at least to me right now.

You could start with what version of the game you trying to mod, and what exactly you're trying to accomplish.

Number of usable actors with proper profiles (including your IMPs, mercs, hire-able NPCs, full-profile shopkeepers, vehicles, etc) is limited to 254 as governed by unsigned byte index (and ID 200 being exempt).

From what I have read around here, programmers, over a decade of doing elaborate and in-deep altering of the original code, have found it to be impossible task to increase this limit; at times going to great lengths of creating whole new systems to somewhat blur the pain this limitation imposes.

Profiles are described in MercProfiles.xml - as far 1.13 is concerned.
Of course, there is also infrastructure of files containing faces, voices etc that supports that list.

But I'm no expert in this, not doing any real modding myself, nor have I read the source code. So what I'm comment is based solely of what I read in discussions around this site.



Re: Source Code Explained[message #347035 is a reply to message #347015] Fri, 23 September 2016 20:59 Go to previous messageGo to next message
Bobby R.

 
Messages:27
Registered:September 2016
@ tais: I didn't meant that but that's also interesting. Thanks.

@ DepressivesBrot: Ok, i will play around with that. Thanks

@ Enneagon: Then i will reformulate the question. What do i have to change in the game code or game files, so that pro-edit shows me, lets say 400 different characters to edit? English is not my first language and its hard to get across what i mean so bear with me bud.
Re: Source Code Explained[message #347036 is a reply to message #347035] Fri, 23 September 2016 21:19 Go to previous messageGo to next message
DepressivesBrot

 
Messages:3743
Registered:July 2009
Bobby R. wrote on Fri, 23 September 2016 19:59
@ Enneagon: Then i will reformulate the question. What do i have to change in the game code or game files, so that pro-edit shows me, lets say 400 different characters to edit? English is not my first language and its hard to get across what i mean so bear with me bud.
Literally (and I know when to use that word) everything.



Need help or just want to kill some time? Visit the Bear's Pit IRC ChannelNote: Say 'Hi' and be patient, it may take a few minutes for someone to react.
Latest 1.13 Builds
My Inbox is for IMPORTANT stuff, NOT random queries about the game.


Re: Source Code Explained[message #347047 is a reply to message #347036] Sat, 24 September 2016 05:52 Go to previous messageGo to next message
Bobby R.

 
Messages:27
Registered:September 2016
That's not very concrete but do you try to hint that the amount of changes that need to be done are so complex that nobody would post that here? I see, then i will just overwrite an existing character for now. My idea was to integrate Bobby Ray as a Shop owner somewhere hidden to find for the player as bonus. The other shops should be available via website too, after an initial conversation with the owner. By the way, i am working on a website for my mod which i will upload in November if somebody is interested to read more about that.

Here is a little preview of Bobby Ray. (I have 3 voices that i still have to decide which of them he will use.)

http://img5.fotos-hochladen.net/uploads/bobbyray0610m1xl48e2pa.png
Re: Source Code Explained[message #347048 is a reply to message #347047] Sat, 24 September 2016 08:11 Go to previous messageGo to next message
edmortimer

 
Messages:779
Registered:January 2015
Location: Home Free
Quote:
i will just overwrite an existing character for now.


If all you want to do is add characters there are empty slots in MercProfiles.xml where characters can be added. In Arulco Vacations I've added 4 vehicles (because they are 'characters' also) and 5 mercs so far. Slot 200 is a no-no, but any other empty slot is OK as far as I know. You should be able to find lots of info on adding characters on this forum. There are several connected XML files that also need to be modified for each character, and then there's the voice files, portrait files, and the EDT/NPC files. For a working example of this you can download Flugente's Commander Shepard character and by examining those files see what you need to do. That's how I learned. You can find Shepard here.




Arulco Vacations Blog

Arulco Vacations Bears Pit Forum

Re: Source Code Explained[message #347049 is a reply to message #347048] Sat, 24 September 2016 09:16 Go to previous message
Bobby R.

 
Messages:27
Registered:September 2016
Hi Ed.

Yeah, i was reading in this and other forums for the last 3 weeks and there is 900 times the same question about that worldwide ;).
But yeah, for now i will use the empty slots. And thanks for the tip with Flugentes Shepard. I downloaded that character already but never thought to backwards engineer it. I feel so powerful all of a sudden. ;) cool
Previous Topic: How to clean G3A3 and Vintorez ?
Next Topic: I just noticed it again - what is the briefing room bookmark and what does it do?
Goto Forum:
  


Current Time: Sun Jun 25 01:32:49 EEST 2017

Total time taken to generate the page: 0.00826 seconds