Author Topic: Understanding Sample Kit .TP2 Code  (Read 2687 times)

Offline Bill Bisco

  • Planewalker
  • *****
  • Posts: 30
Understanding Sample Kit .TP2 Code
« on: April 16, 2016, 10:44:57 PM »
I have some questions about a section of the .TP2 file code from the Shadowdancer kit.

Code: [Select]
ADD_KIT ~A#SHADOWDANCER~
~A#SHADOWDANCER                  1           1           1           1           1           0           0           0~
~A#SHADOWDANCER 0 1 0 0 1 0 0 1 0 1 1 0 0 1 1 1 0 1 0 0 0 0 1 1 0 1 1 1 1 1 1 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0~
~A#SHADOWDANCER 0 9 0 0 0 0~
~A#SHADOWDANCER 0 0 0 0 0 0~
~A#SHADOWDANCER 0 0 0 0 0 0~
~A#SHADOWDANCER 0 0 0 0 0 0~
~A#SHADOWDANCER 1 1 1 1 1 1 1 1 1~
~A#SHADOWDANCER 0 0 0 0 0 0~
~song_and_silence/shadowdancer/a#shad.2da~
~K_T_H    K_T_D   K_T_G   K_T_E   K_T_HE   K_T_HL   K_T_HO~
~0x00040000 4~
~th0~

I think I understand the first 8 lines.  These are modifying 8 .2DA files.  However, I don't understand the line

Code: [Select]
~song_and_silence/shadowdancer/a#shad.2da~
The file it refers to is below.

Code: [Select]
2DA V1.0
****       
           1         2          3          4          5          6          7          8          9          10         11         12         13         14         15         16         17         18         19         20         21         22         23         24         25         26         27         28         29         30         31         32         33         34         35         36         37         38         39         40         
ABILITY1   GA_A#SD3  ****       ****       ****       ****       ****       ****       GA_A#SD5   ****       ****       ****       ****       ****       GA_A#SD5   ****       ****       ****       ****       ****       GA_A#SD5   ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****
ABILITY2   AP_A#SD1  ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****       AP_A#SD1   ****
ABILITY3   AP_A#SD2  ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****
ABILITY4   ****      ****       ****       ****       GA_A#Shad4 ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****
ABILITY5   ****      ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****
ABILITY6   ****      ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****       ****

How does that line work?  If you include that you automatically append the game's files and give abilities a time and place to work?

The file above looks remarkably like the CLABXX.2DA File structure

http://gibberlings3.net/iesdp/files/2da/2da_tob/clabxx00.htm
Code: [Select]
2DA V1.0
    ****
                1           2           3           4           5           6           7           8           9           10          11          12          13          14          15          16          17          18          19          20         21          22          23          24          25          26          27          28          29          30          31          32          33          34          35          36          37          38          39          40
    ABILITY1    GA_SPCL811  ****        ****        ****        GA_SPCL811  ****        GA_SPCL815  AP_SPCL816  GA_SPCL811  ****        AP_SPCL818  AP_SPCL816  GA_SPCL811  AP_SPCL819  ****        ****        GA_SPCL811  ****        ****        AP_SPCL821 GA_SPCL811  ****        ****        ****        GA_SPCL811  ****        ****        ****        GA_SPCL811  ****        ****        ****        GA_SPCL811  ****        ****        ****        GA_SPCL811  ****        ****        ****
    ABILITY2    AP_SPCL812  ****        ****        ****        AP_SPCL813  ****        ****        ****        AP_SPCL817  AP_SPCL813  ****        ****        GA_SPCL820  AP_SPCL819  AP_SPCL813  ****        ****        ****        ****        AP_SPCL813 ****        ****        ****        ****        AP_SPCL813  ****        ****        ****        ****        AP_SPCL813  ****        ****        ****        ****        AP_SPCL813  ****        ****        ****        ****        AP_SPCL813
    ABILITY3    ****        ****        ****        ****        AP_SPCL814  ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819 AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819  AP_SPCL819  ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY4    ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY5    ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY6    ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY7    ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY8    ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY9    ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY10   ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY11   ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY12   ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY13   ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ****        ****        ****        ****        ****        ****       ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****
    ABILITY14   ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        ****        AP_SPCL819  ***

1. I don't understand referencing this file just makes Weidu make it work?  It doesn't start with CLAB.

2. I don't understand why this line works

~K_T_H    K_T_D   K_T_G   K_T_E   K_T_HE   K_T_HL   K_T_HO~


This looks like it's modifying http://gibberlings3.net/iesdp/files/2da/2da_tob/kittable.htm   with Kittable.2DA

The file is never referenced.  How does Weidu know which file is being appended?  Can I include the code for any of these files' values and trust Weidu to append it correctly?

3.  I don't understand why these are here.  Can someone please tell me?

Code: [Select]
~0x00040000 4~
~th0~

Offline Mike1072

  • Planewalker
  • *****
  • Posts: 298
  • Gender: Male
Re: Understanding Sample Kit .TP2 Code
« Reply #1 on: April 17, 2016, 12:24:19 AM »
You should read CamDawg's 4-part Kit Creation tutorial.

 

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Name: Email:
Verification:
Type the letters shown in the picture
Listen to the letters / Request another image
Type the letters shown in the picture:
What color is grass?:
What is the seventh word in this sentence?:
What is five minus two (use the full word)?: