Home » MODDING HQ 1.13 » v1.13 Modding, Customising, Editing » v1.13 Modding, Customising, Editing » Need help with the JSD Editor
| Need help with the JSD Editor[message #254327]
|
Sat, 19 June 2010 20:17
|
|
smeagol |
 |
Messages:2704
Registered:June 2008 Location: Bremen, Germany |
|
|
Is there somewhere a manual//readme file that explains the rather cryptic options in the JSD editor by Pipetz?
I managed to set most stuff to English, but there are quite a lot of things I couldn't figure out... (like for example what certain flags actually do...).
Atm, I'm trying to fix the "kevlar grass" in the WF tilesets. A rather annoying thing is, that highgrass found in most maps cuts down CTH to 0. I'd like to have the CTH set to a rather acceptable value, while still cutting down sight range//detection range a bit.
If someone who knows how to operate the JSD Editor could shed some knowledge, that would be great 
For example, what are the Offs X, Offs Y, Vitality, Density, etc... (and all the other tags that can be found...). What exactly do those values stand for (for example, what exactly does Density 100 compared to Density 30...).
Also a description of the flags would good (well, some of them are quite self-explanatory, but some others are quite cryptic :/ ).
I tried to figure this out, but somehow I'm lost.
Report message to a moderator
|
|
|
|
|
|
|
| Re: Need help with the JSD Editor[message #254515]
|
Tue, 22 June 2010 01:54 
|
|
BirdFlu |
 |
Messages:438
Registered:September 2007 Location: Lampukistan |
|
|
I have looked into the kevlar grass issue with the F_WEED.jsd file (the one in tilesets/0/.). I think the main problem is that it is considered a tree (STRUCTURE_TREE), thus the tree handling code is activated during the Chance-to-hit computation. In this computation the sight limit gets adjusted and if it falls below the distance to the target then you get the AIM_PENALTY_BLIND, which is 80 points (in words eighty). Unfortunately the density of the structure doesn't seem to be considered for the chance to hit computation (at least for trees), only the shape. But the density is 100 anyway for the grass. I've briefly seen other places in the code, where density in considered, but it think it applies only to fences.
So, after this first look at this problem i would say that the best chance would probably be to make the grass a fence (STRUCTURE_FENCE or maybe STRUCTURE_WIREFENCE) and set the density to something below 100.
But on the other hand, isn't this kind of the wanted/desired behaviour? If you cannot see the target you consequently cannot hit it (reduced probability). Then. of course, the blindness penalty shouldn't necessarily be static, but instead vary with the distance to the target. Longer distances give a penalty of 80 points, shorter ones maybe only 50 points.
Report message to a moderator
|
|
|
|
|
| Re: Need help with the JSD Editor[message #254518]
|
Tue, 22 June 2010 02:28 
|
|
| Headrock |
 |
Messages:1757
Registered:March 2006 Location: Jerusalem |
|
|
Density won't only change CTH, it also changes likelyhood for a bullet to pass through an object without causing a collision. I bet it also governs how likely the bullet is to pass through if it DOES hit the structure, but I may be mistaken (haven't actually looked for that). In either case, since density isn't taken into account when looking through an object (only the structure type, as Birdflu mentioned), changing it from a tree to soemthing else may be the best solution.
Here's the list:
// NOT used in DB structures
STRUCTURE_BASE_TILE = 0x00000001,
STRUCTURE_OPEN = 0x00000002,
STRUCTURE_OPENABLE = 0x00000004,
STRUCTURE_MOBILE = 0x00000010,
/* STRUCTURE_PASSABLE is set for each structure instance where the tile flag
* TILE_PASSABLE is set */
STRUCTURE_PASSABLE = 0x00000020,
STRUCTURE_EXPLOSIVE = 0x00000040,
STRUCTURE_TRANSPARENT = 0x00000080,
STRUCTURE_GENERIC = 0x00000100,
STRUCTURE_TREE = 0x00000200,
STRUCTURE_FENCE = 0x00000400,
STRUCTURE_WIREFENCE = 0x00000800,
STRUCTURE_HASITEMONTOP = 0x00001000, // ATE: struct has item on top of it
STRUCTURE_SPECIAL = 0x00002000,
STRUCTURE_LIGHTSOURCE = 0x00004000,
STRUCTURE_VEHICLE = 0x00008000,
STRUCTURE_WALL = 0x00010000,
STRUCTURE_WALLNWINDOW = 0x00020000,
STRUCTURE_SLIDINGDOOR = 0x00040000,
STRUCTURE_DOOR = 0x00080000,
/* a "multi" structure (as opposed to multitiled) is composed of multiple
* graphics & structures */
STRUCTURE_MULTI = 0x00100000,
STRUCTURE_CAVEWALL = 0x00200000,
STRUCTURE_DDOOR_LEFT = 0x00400000,
STRUCTURE_DDOOR_RIGHT = 0x00800000,
STRUCTURE_NORMAL_ROOF = 0x01000000,
STRUCTURE_SLANTED_ROOF = 0x02000000,
STRUCTURE_TALL_ROOF = 0x04000000,
STRUCTURE_SWITCH = 0x08000000,
STRUCTURE_ON_LEFT_WALL = 0x10000000,
STRUCTURE_ON_RIGHT_WALL = 0x20000000,
STRUCTURE_CORPSE = 0x40000000,
STRUCTURE_PERSON = 0x80000000,
// Combination flags
STRUCTURE_ANYFENCE = 0x00000C00,
STRUCTURE_ANYDOOR = 0x00CC0000,
STRUCTURE_OBSTACLE = 0x00008F00,
STRUCTURE_WALLSTUFF = 0x00CF0000,
STRUCTURE_BLOCKSMOVES = 0x00208F00,
STRUCTURE_TYPE_DEFINED = 0x8FEF8F00,
STRUCTURE_ROOF = 0x07000000
Unfortunately, it'll take some work to actually tell you what each type does. However, if "GENERIC" doesn't work, the second best bet would be "PASSABLE".
Report message to a moderator
|
|
|
|
|
| Re: Need help with the JSD Editor[message #254534]
|
Tue, 22 June 2010 10:22 
|
|
| Logisteric |
  |
Messages:3190
Registered:December 2008 Location: B |
|
|
BirdFluI have looked into the kevlar grass issue with the F_WEED.jsd file (the one in tilesets/0/.). I think the main problem is that it is considered a tree (STRUCTURE_TREE), thus the tree handling code is activated during the Chance-to-hit computation. In this computation the sight limit gets adjusted and if it falls below the distance to the target then you get the AIM_PENALTY_BLIND, which is 80 points (in words eighty). Unfortunately the density of the structure doesn't seem to be considered for the chance to hit computation (at least for trees), only the shape. But the density is 100 anyway for the grass. I've briefly seen other places in the code, where density in considered, but it think it applies only to fences.
So, after this first look at this problem i would say that the best chance would probably be to make the grass a fence (STRUCTURE_FENCE or maybe STRUCTURE_WIREFENCE) and set the density to something below 100.
But on the other hand, isn't this kind of the wanted/desired behaviour? If you cannot see the target you consequently cannot hit it (reduced probability). Then. of course, the blindness penalty shouldn't necessarily be static, but instead vary with the distance to the target. Longer distances give a penalty of 80 points, shorter ones maybe only 50 points.
just a thought - in such an area you would lead up the air in the direction of the sound with an lmg (7.52 would be my choice) - you should hit someone (lmg-wise) even if you don't see them - is there a chance to have it spread between a heavy hindrance in sight and far less deflection for bullets (especially heavy ones) - as it is now you better use grenades if the baddie is just two tiles of the road in heavy grass AND you see him - to me that is totally wrong
Report message to a moderator
|
Captain
|
|
|
|
| Re: Need help with the JSD Editor[message #254543]
|
Tue, 22 June 2010 12:14 
|
|
smeagol |
 |
Messages:2704
Registered:June 2008 Location: Bremen, Germany |
|
|
Okay, thanks for the explantaions.
BirdFluSo, after this first look at this problem i would say that the best chance would probably be to make the grass a fence (STRUCTURE_FENCE or maybe STRUCTURE_WIREFENCE) and set the density to something below 100.
Though wouldn't setting it to STRUCTURE_FENCE make it jumpable and STRUCTURE_WIREFENCE make it cutable without a second animation? (hmmm.... maybe this would be a nice, but tedious use for wire cutters... or maybe bring back Reubans hedge trimmer for this ^^).
Edit2: On a second note though, why is it possible to jump certain sandbags and not others. all sandbags have the same flags set... weird. Is that somehow related to the objects height set in the 3D pic? But that again would contradict several other items in the file, which have the same height as the jumpable sandbags but can't be jumped over.... ahhhhhhhhh confusing stuff.
BirdFluBut on the other hand, isn't this kind of the wanted/desired behaviour? If you cannot see the target you consequently cannot hit it (reduced probability). Then. of course, the blindness penalty shouldn't necessarily be static, but instead vary with the distance to the target. Longer distances give a penalty of 80 points, shorter ones maybe only 50 points.
Yes, a dynmaic penalty would be the best solution. However, as long as that isn't possible I'd take a static one any day of the week, as long as it isn't like "guy 4 tiles away standing in High Grass = 0 CTH".
Logijust a thought - in such an area you would lead up the air in the direction of the sound with an lmg (7.52 would be my
choice)
Well... good look finding ammo for that. :pitchfork:
HeadrockHere's the list:
Code:
// NOT used in DB structures
STRUCTURE_BASE_TILE = 0x00000001,
STRUCTURE_OPEN = 0x00000002,
STRUCTURE_OPENABLE = 0x00000004,
STRUCTURE_MOBILE = 0x00000010,
/* STRUCTURE_PASSABLE is set for each structure instance where the tile flag
* TILE_PASSABLE is set */
STRUCTURE_PASSABLE = 0x00000020,
STRUCTURE_EXPLOSIVE = 0x00000040,
STRUCTURE_TRANSPARENT = 0x00000080,
STRUCTURE_GENERIC = 0x00000100,
STRUCTURE_TREE = 0x00000200,
STRUCTURE_FENCE = 0x00000400,
STRUCTURE_WIREFENCE = 0x00000800,
STRUCTURE_HASITEMONTOP = 0x00001000, // ATE: struct has item on top of it
STRUCTURE_SPECIAL = 0x00002000,
STRUCTURE_LIGHTSOURCE = 0x00004000,
STRUCTURE_VEHICLE = 0x00008000,
STRUCTURE_WALL = 0x00010000,
STRUCTURE_WALLNWINDOW = 0x00020000,
STRUCTURE_SLIDINGDOOR = 0x00040000,
STRUCTURE_DOOR = 0x00080000,
/* a "multi" structure (as opposed to multitiled) is composed of multiple
* graphics & structures */
STRUCTURE_MULTI = 0x00100000,
STRUCTURE_CAVEWALL = 0x00200000,
STRUCTURE_DDOOR_LEFT = 0x00400000,
STRUCTURE_DDOOR_RIGHT = 0x00800000,
STRUCTURE_NORMAL_ROOF = 0x01000000,
STRUCTURE_SLANTED_ROOF = 0x02000000,
STRUCTURE_TALL_ROOF = 0x04000000,
STRUCTURE_SWITCH = 0x08000000,
STRUCTURE_ON_LEFT_WALL = 0x10000000,
STRUCTURE_ON_RIGHT_WALL = 0x20000000,
STRUCTURE_CORPSE = 0x40000000,
STRUCTURE_PERSON = 0x80000000,
// Combination flags
STRUCTURE_ANYFENCE = 0x00000C00,
STRUCTURE_ANYDOOR = 0x00CC0000,
STRUCTURE_OBSTACLE = 0x00008F00,
STRUCTURE_WALLSTUFF = 0x00CF0000,
STRUCTURE_BLOCKSMOVES = 0x00208F00,
STRUCTURE_TYPE_DEFINED = 0x8FEF8F00,
STRUCTURE_ROOF = 0x07000000
Your list misses the flag: STRUCTURE_HIDDEN between STRUCTURE_OPENABLE and STRUCTURE_MOBILE, this applies for example to sandbags and barbed wire (maybe this relates to generating the radar maps so that those won't show up on the radar map... just a wild guess...).
The question remains, if the changed jsd has to be in each folder of the tileset or if it is sufficient to have it in folder "0".
Also I think that the bullet goes through thing is also related to the objects armor. You can shoot through wood walls (and even kill bad guys behind it, with a 12.7 bullet... one of the best things to go for ^^), although they have density 100 for example.
[Updated on: Tue, 22 June 2010 12:51] by Moderator Report message to a moderator
|
|
|
|
|
| Re: Need help with the JSD Editor[message #254625]
|
Wed, 23 June 2010 01:34 
|
|
BirdFlu |
 |
Messages:438
Registered:September 2007 Location: Lampukistan |
|
|
smeagolThe question remains, if the changed jsd has to be in each folder of the tileset or if it is sufficient to have it in folder "0".
The important files are the sti images. What images are loaded is specified in ja2set.dat (or ja2set.dat.xml). When a map is loaded, then all tileset images for a given tileset number are loaded too. When a file index in the tileset file list is empty (e.g., 8 for tileset 11), then the file with the same file index is taken from tileset 0.
Whenever a tileset image is loaded (filename : tilesets/x/abc.sti) the game also tries to load a structure file (filename : tilesets/x/abc.jsd). So, for example, the f_weed.sti (and f_weed.jsd) is on position 97 in tileset 0 and on position 16 in tileset 11, whereas on position 97 in tileset 1 you will find f_corn.sti.
To answer your question, if you want to use a non-standard image f_weeds.sti in your tileset, the you also have to provide a jsd file in the same directory. Structure files are not shared between images or even tilesets. And if you want a different image and not the default one, then the structure probably has changed too, so, using a new jsd file makes sense. And if the structure has not changed also the visuals have, you still have to make a copy.
Report message to a moderator
|
|
|
|
|
|
|
Goto Forum:
Current Time: Thu Jun 11 02:12:35 GMT+3 2026
Total time taken to generate the page: 0.00711 seconds
|