Author Topic: Beta 238.02  (Read 1781 times)

Offline Wisp

  • Moderator
  • Planewalker
  • *****
  • Posts: 1176
Beta 238.02
« on: January 09, 2016, 04:09:13 PM »
Because reasons, today's beta version is brought to you by Dropbox.

Windows package
GNU/Linux Package
Readme
Changes

Changes since 238.01:
  • WeiDU does not verify trigger or action lists during --traify.
  • DELETE can recursively delete directories and everything in them.
  • RES_NAME_OF_SPELL_NUM, RES_NUM_OF_SPELL_NAME and NAME_NUM_OF_SPELL_RES are also available as patch functions and macros.
  • NAME_NUM_OF_SPELL_RES matches resource references case-insensitively.
  • Fix regression in OR() indentation.
  • Fix documentation of fj_are_structure: the spawn-point variable fj_base_num is unused and its functionality is implemented through the variable fj_difficulty.
  • Add fj_(pitch|volume)_variance to fj_are_structure's ambient variables.
  • To save time, WeiDU will not ask what should be done about components which cannot be installed.
  • CLONE_EFFECT fails louder on files with invalid signatures.
  • --force-uninstall-rest works as described.
  • As per readme, --safe-exit cannot be used together with --uninstall and friends.
  • Add EE_LANGUAGE variable.
  • Fix compatibility issue that had WeiDU resort to dumb-terminal behaviour on modern terminal emulators.
  • The functions (DELETE|CLONE)_EFFECT do not misindex files under certain conitions.
  • The ADD_SPELL_EFFECT, ADD_ITEM_EFFECT, ADD_ITEM_EQEFFECT and ADD_CRE_EFFECT functions support setting the special parameter. The corresponding macros do NOT support this.
  • The ALTER_(ITEM|SPELL)_EFFECT functions support altering the special parameter.
  • The functionality of the ALTER_AREA_* functions has been expanded.
  • Document EDIT_SAV_FILE.
  • TP2 precedence order is now MyMod/MyMod.tp2, MyMod/Setup-MyMod.tp2, MyMod.tp2, Setup-MyMod.tp2.
« Last Edit: January 09, 2016, 04:18:43 PM by Wisp »

Offline Wisp

  • Moderator
  • Planewalker
  • *****
  • Posts: 1176
Re: Beta 238.02
« Reply #1 on: January 24, 2016, 05:55:18 AM »
So, everything good? It feels more like progress when there are bug reports coming in.

Offline Argent77

  • Planewalker
  • *****
  • Posts: 187
Re: Beta 238.02
« Reply #2 on: January 24, 2016, 01:14:17 PM »
I have an issue to report which is not related to the list of changes in the first post.

In the process of inspecting NI's BCS compiler code I have noticed a bug in WeiDU's script compiler when generating BCS code from object identifiers for IWD2. Based on IESDP the second to last object identifier slot refers to AVCLASS.IDS which is only used in IWD2. However, this file does not exist in this game. Instead, the file CLASS20.IDS seems to be the most likely candidate for this slot (information about IWD2 scripting are very scarce).

WeiDU attempts to look up values in AVCLASS.IDS which results in compiler errors if a symbolic value is used. The WeiDU betas also prints error messages when decompiling BCS files using this target identifier, but still generate complete BAF files. The script files 61PPCIRC.BCS, 41PRIEST.BCS and 00DDRW0.BCS make use of this identifier slot for targetting purposes.
« Last Edit: January 24, 2016, 01:19:18 PM by Argent77 »

Offline Wisp

  • Moderator
  • Planewalker
  • *****
  • Posts: 1176
Re: Beta 238.02
« Reply #3 on: January 24, 2016, 02:36:20 PM »
The more I learn of IWD2, the more I hate it. Do the scripts you mention work right when CLASS20 is used for lookup? If so, I'll just change AVCLASS into CLASS20 and call it good.

Offline Argent77

  • Planewalker
  • *****
  • Posts: 187
Re: Beta 238.02
« Reply #4 on: January 24, 2016, 03:35:34 PM »
I have made some tests with custom scripts, since the targets in the aforementioned scripts are actually overspecified. It looks like this value is not used at all in the game as it always returns true. I suppose it's safe to change AVCLASS into an existing IDS reference. I've mentioned CLASS20 in my previous post as it was the only IDS reference in CRE files not used as IDS target, but it looks like that CLASS fits better as the values in the game scripts always use the same value as in the CLASS slot.
« Last Edit: January 24, 2016, 03:42:53 PM by Argent77 »

Offline Argent77

  • Planewalker
  • *****
  • Posts: 187
Re: Beta 238.02
« Reply #5 on: February 04, 2016, 04:23:57 PM »
I've noticed a few issues in the WeiDU Readme:

1. The tutorial for ADD_STORE_ITEM doesn't mention that you have to specify "NONE" for empty flags.
2. Links from entries in the dialog syntax table (chapter 4) or TP2 syntax table (chapter 9) to their respective tutorials don't work. Examples are INTERJECT_COPY_TRANS or ALTER_TRANS in the Dialog table and ADD_STORE_ITEM, ADD_GAM_NPC or SUBCOMPONENT in the TP2 table.

I also have a question about the REQUIRE_xxx flags. Assuming my mod contains a main component 1 and a secondary component 2 which can only be installed if component 1 has been selected.
When I'm using the following flag for component 2
Code: [Select]
REQUIRE_COMPONENT ~setup-xyz.tp2~ 1 ~Component 1 required!~then component 2 is automatically uninstalled when I'm uninstalling component 1.

When I'm using the following flag instead
Code: [Select]
REQUIRE_PREDICATE (MOD_IS_INSTALLED ~setup-xyz.tp2~ 1) ~Component 1 required!~then component 2 is automatically uninstalled as well, but WeiDU still asks what to do with this component. None of the available options appear to work as expected though. For example, selecting "Quit" displays the message "[XYZ/SETUP-XYZ.TP2] component 2  fails component requirements, *not* Re-Installing.". Shouldn't this construct behave the same way as REQUIRE_COMPONENT?
« Last Edit: February 04, 2016, 04:56:28 PM by Argent77 »

Offline Wisp

  • Moderator
  • Planewalker
  • *****
  • Posts: 1176
Re: Beta 238.02
« Reply #6 on: February 05, 2016, 02:47:30 PM »
1. The tutorial for ADD_STORE_ITEM doesn't mention that you have to specify "NONE" for empty flags.
Will fix.

2. Links from entries in the dialog syntax table (chapter 4) or TP2 syntax table (chapter 9) to their respective tutorials don't work. Examples are INTERJECT_COPY_TRANS or ALTER_TRANS in the Dialog table and ADD_STORE_ITEM, ADD_GAM_NPC or SUBCOMPONENT in the TP2 table.
Because reasons, HeVeA is now producing incomplete HTML for references constructed like these. I'll see what I can do.

I also have a question about the REQUIRE_xxx flags. Assuming my mod contains a main component 1 and a secondary component 2 which can only be installed if component 1 has been selected.
When I'm using the following flag for component 2
Code: [Select]
REQUIRE_COMPONENT ~setup-xyz.tp2~ 1 ~Component 1 required!~then component 2 is automatically uninstalled when I'm uninstalling component 1.

When I'm using the following flag instead
Code: [Select]
REQUIRE_PREDICATE (MOD_IS_INSTALLED ~setup-xyz.tp2~ 1) ~Component 1 required!~then component 2 is automatically uninstalled as well, but WeiDU still asks what to do with this component. None of the available options appear to work as expected though. For example, selecting "Quit" displays the message "[XYZ/SETUP-XYZ.TP2] component 2  fails component requirements, *not* Re-Installing.". Shouldn't this construct behave the same way as REQUIRE_COMPONENT?
From v190:
Quote
  * Failing mod flags will lead to uninstallation, except for the tricky 'can become false'
    ones, such as FORBID_FILE, FORBID_COMPONENT and REQUIRE_PREDICATE.
« Last Edit: February 05, 2016, 02:57:45 PM by Wisp »

 

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)?: