Jump to content


Photo

aTweaks corrupting .cre files?


  • Please log in to reply
11 replies to this topic

#1 Hnyakwai

Hnyakwai
  • Member
  • 5 posts

Posted 25 October 2010 - 03:07 PM

Hi,

I have been working on getting a BWP install to work for the last few days, and I have been having big problems with infinity animations and crefixer crashing with bugarch.cre and bugbear.cre. Finally I traced the files through each backup directory chronologically, opening them each with nearInfinity. I found that I could open the cre files in the aTweaks backup folder but not the ones in the xpmod folder (the next mod that touched those files).

When I found this problem I disabled aTweaks component 140 and tried to install again. This fixed the problem with bugbear.cre and bugarch.cre, but then crefixer crashed on the file ntkrotan.cre which was modified in component 130. I just tried to open up a bunch of the final biffed files that were modified by aTweaks and I can't open any of them. In the nearInfinity debug window it looks like it is failing some sort of range check:

Spoiler


Furthermore (and I just figured this out while I was constructing this post), these corrupted cre files are causing a CTD that I posted about here: BWP 9.5 failure

The crash happens when ogre.cre is loaded in forest.

Spoiler


Any ideas what the problem is here?

Weidu.log:

Spoiler


#2 GeN1e

GeN1e

    A very GAR character

  • Modder
  • 1604 posts

Posted 25 October 2010 - 04:50 PM

I've already reported ADD_CRE_EFFECT macro, used by these components too, as messing up files which use non-standart order. Still, aTweaks makes a use of Nythrun's re-indexing code, so I wonder why they weren't fixed...

Checking her code might also be a good idea (I've found one typo in spl/itm re-indexer), but I can't do it properly this time of day.

Edited by GeN1e, 25 October 2010 - 05:05 PM.

Retired from modding.


#3 Miloch

Miloch

    Barbarian

  • Modder
  • 6579 posts

Posted 25 October 2010 - 07:39 PM

Checking her code might also be a good idea (I've found one typo in spl/itm re-indexer), but I can't do it properly this time of day.

Do tell more details once you wake up (or whatever).

As for the original post - I can say only that offhand I don't know what might be causing such discrepancies. I don't think it's the cre/itm macros though since many mods have been using at least the former without any repurcussions I know of. I can also say that I wish every bug report post were so detailed. Actually tracing .cre errors through successive backups is just spectacular :cheers:. If Wisp can't figure it out (though I've no doubt he can) I'll try taking a look at it.

Um, I suppose I should ask which codepage your system is using. Because if not a Western European one, then Infinity Animations could be causing it, but it sounds like you traced it to something from before you installed that.

Infinity Engine Contributions
Aurora * BG1 NPC * BG1 Fixpack * Haiass * Infinity Animations * Level 1 NPCs * P5Tweaks
PnP Free Action * Thrown Hammers * Unique Containers * BG:EE * BGII:EE * IWD:EE
================================================================
Player & Modder Resources
BAM Batcher * Creature Lister * Creature Checker * Creature Fixer * Tutu/BGT Area Map & List * Tutu Mod List
================================================================
"Infinity turns out to be the opposite of what people say it is. It is not 'that which has nothing beyond itself' that is infinite, but 'that which always has something beyond itself'." -Aristotle


#4 Hnyakwai

Hnyakwai
  • Member
  • 5 posts

Posted 25 October 2010 - 07:51 PM

Um, I suppose I should ask which codepage your system is using. Because if not a Western European one, then Infinity Animations could be causing it, but it sounds like you traced it to something from before you installed that.


What do you mean by codepage?  I'm in North America so I guess I probably don't have a Western European codepage.  I think I run about 10 BWP installs this weekend and I have been rolling back with BWS setup.  I think it is time for me to wipe everything else and try from scratch, do I need to disable IA with a North American computer?

#5 Miloch

Miloch

    Barbarian

  • Modder
  • 6579 posts

Posted 25 October 2010 - 08:17 PM

What do you mean by codepage? I'm in North America so I guess I probably don't have a Western European codepage. I think I run about 10 BWP installs this weekend and I have been rolling back with BWS setup. I think it is time for me to wipe everything else and try from scratch, do I need to disable IA with a North American computer?

No, heh, there's no issues there, since North America = Western European codepages (English, Spanish, French, etc.). It only really becomes an issue with Russian, Chinese, etc. So I wouldn't worry about that. On the other hand, maybe you could attach (should be able to do that if you're registered, which you are) the .cre files from your --change-log. In other words, just zip BUGARCH.0001.CRE to BUGARCH.0010.CRE (or whatever) after doing said --change-log (which you've done I think) and attach that archive here.

Infinity Engine Contributions
Aurora * BG1 NPC * BG1 Fixpack * Haiass * Infinity Animations * Level 1 NPCs * P5Tweaks
PnP Free Action * Thrown Hammers * Unique Containers * BG:EE * BGII:EE * IWD:EE
================================================================
Player & Modder Resources
BAM Batcher * Creature Lister * Creature Checker * Creature Fixer * Tutu/BGT Area Map & List * Tutu Mod List
================================================================
"Infinity turns out to be the opposite of what people say it is. It is not 'that which has nothing beyond itself' that is infinite, but 'that which always has something beyond itself'." -Aristotle


#6 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 26 October 2010 - 03:05 AM

Yes, a few pre-aTweaks files and the corresponding post-aTweaks files would be nice, so I can see how the files have been screwed up. In the meantime I guess I have some code to pore over.

Edited by Wisp, 26 October 2010 - 10:42 AM.


#7 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 26 October 2010 - 10:40 AM

Mhmm, the problem's with ADD_CRE_EFFECT_BG2. I assume it has worked in the past but now it breaks any cre file where the value of fx_off isn't the lowest of the bunch, i.e. even cre files following the standard order. There's a corresponding problem with DELETE_CRE_EFFECT.

Edited by Wisp, 26 October 2010 - 10:43 AM.


#8 GeN1e

GeN1e

    A very GAR character

  • Modder
  • 1604 posts

Posted 26 October 2010 - 10:55 AM

Checking her code might also be a good idea (I've found one typo in spl/itm re-indexer), but I can't do it properly this time of day.

Do tell more details once you wake up (or whatever).

Nothing fancy, an in overwhelming majority of cases is harmless. It doesn't do ~WRITE_SHORT 0x6e 0~, the starting index for global effects. Not that I've seen any one with non-zero yet.

Hm, maybe these codes should be included in WeiDU as well?

I don't think it's the cre/itm macros though since many mods have been using at least the former without any repurcussions I know of.

Consider yourself one lucky orc :)

Edited by GeN1e, 26 October 2010 - 10:58 AM.

Retired from modding.


#9 Miloch

Miloch

    Barbarian

  • Modder
  • 6579 posts

Posted 26 October 2010 - 11:18 AM

Mhmm, the problem's with ADD_CRE_EFFECT_BG2. I assume it has worked in the past but now it breaks any cre file where the value of fx_off isn't the lowest of the bunch, i.e. even cre files following the standard order. There's a corresponding problem with DELETE_CRE_EFFECT.

Is there a similar problem with SET_BG2_PROFICIENCY, since it also adds effects?

Hm, maybe these codes should be included in WeiDU as well?

I suppose, but someone would have to write documentation. Which I guess should be fairly easy for these, but still...

I don't think it's the cre/itm macros though since many mods have been using at least the former without any repurcussions I know of.

Consider yourself one lucky orc :)

The only thing I've seen is that they *can't* fix some resources if they're hopelessly hosed (via editing with Near Infinity or the like). But I don't know if that's even possible via code (I suppose it could be for the likes of Nythrun, but I'm not going to attempt it).

Infinity Engine Contributions
Aurora * BG1 NPC * BG1 Fixpack * Haiass * Infinity Animations * Level 1 NPCs * P5Tweaks
PnP Free Action * Thrown Hammers * Unique Containers * BG:EE * BGII:EE * IWD:EE
================================================================
Player & Modder Resources
BAM Batcher * Creature Lister * Creature Checker * Creature Fixer * Tutu/BGT Area Map & List * Tutu Mod List
================================================================
"Infinity turns out to be the opposite of what people say it is. It is not 'that which has nothing beyond itself' that is infinite, but 'that which always has something beyond itself'." -Aristotle


#10 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 26 October 2010 - 12:26 PM

Is there a similar problem with SET_BG2_PROFICIENCY, since it also adds effects?

I don't think so. The problems I identified were the results of alterations made to Gort's macros in WeiDU 221. SET_BG2_PROFICIENCY is completely separate (written in OCaml, even) as far as I know.

Hnyakwai, which version of WeiDU did you use to install aTweaks (it should say at the top of the aTweaks debug file)?
WeiDU 221 was released pretty recently and I want to be sure the problems I found are not a different from the problems you are having (though that would be pretty unlikely).

#11 Hnyakwai

Hnyakwai
  • Member
  • 5 posts

Posted 26 October 2010 - 01:56 PM


Is there a similar problem with SET_BG2_PROFICIENCY, since it also adds effects?

I don't think so. The problems I identified were the results of alterations made to Gort's macros in WeiDU 221. SET_BG2_PROFICIENCY is completely separate (written in OCaml, even) as far as I know.

Hnyakwai, which version of WeiDU did you use to install aTweaks (it should say at the top of the aTweaks debug file)?
WeiDU 221 was released pretty recently and I want to be sure the problems I found are not a different from the problems you are having (though that would be pretty unlikely).

I was using WeiDU 221.  After I reported this I did a completely clean install (and since I was tired of debugging after 48 hours or so of constant struggle, I disabled anything that I thought could possibly corrupt my install... which means no aTweaks this time)  I dug up the files from the BWS backups though.  Your mod looks like it has a lot of great features, so I would definitely like to install it next time I reinstall.

Attached Files



#12 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 26 October 2010 - 02:07 PM

I was using WeiDU 221. After I reported this I did a completely clean install (and since I was tired of debugging after 48 hours or so of constant struggle, I disabled anything that I thought could possibly corrupt my install... which means no aTweaks this time) I dug up the files from the BWS backups though. Your mod looks like it has a lot of great features, so I would definitely like to install it next time I reinstall.

Unfortunately this bug's rather far-reaching. If you axed enough mods you may not be affected, but it's definitely not limited to aTweaks. If you can use NI you can use it to search for corrupted creatures (Tools->Find corrupted files) to see if you will run into more problems related to this. And if you should happen to need/want to reinstall again, wait until WeiDU 222 has been released (which should be announced e.g. here).

Edited by Wisp, 26 October 2010 - 02:11 PM.