Jump to content


Photo

Error when exiting RotWK mod. [SOLVED]


  • Please log in to reply
7 replies to this topic

#1 Titan Cronus

Titan Cronus

    Do unto Others...

  • Members
  • 693 posts
  • Location:Ireland
  • Projects:The Battle of the Pelennor Fields Mod.

Posted 03 August 2015 - 07:55 PM

Hey again guys.

 

I'm sorry but you might have to tolerate me making new posts every few hours for a few more days yet guys. Just until I have re-mastered my code-fu. :thumbsupxd:

 

I was doing some editing today, giving a hero a new ability and at some point, I started getting errors when exiting the game. It's the usual "The Battle for Middle-earth II has stopped working" error but if I remember from when I was modding before, I'm sure that was itself an indicator of what type of problem it was. Like a file naming issue or something like that. Am I remembering correctly or have I misremembered?

 

Thanks a million guys.


Edited by Titan Cronus, 03 August 2015 - 10:38 PM.

Battle of the Pelennor Fields

Made by 1 guy, has 13 Factions, 75+ Heroes, 150+ different units and 200+ Special abilities.

 

http://www.moddb.com...pelennor-fields


#2 Titan Cronus

Titan Cronus

    Do unto Others...

  • Members
  • 693 posts
  • Location:Ireland
  • Projects:The Battle of the Pelennor Fields Mod.

Posted 03 August 2015 - 10:38 PM

Hey again guys.

 

Righty, I found the problem. I seemed to have had two entries for the same unit in the experiencelevels ini, For some reason, the game never seemed to have minded until I edited one of them today. I'm guessing that because both entries were identical before, It didn't cause a problem (which is really surprising to me) but after I changed one entry, it became a problem. ANyhoo, I deleted one and now its all good.

 

Sorry for the stupid post. I really should have just been more patient and kept at it but I was just hoping someone might have had a quick tip to point me in the right direction.

 

Anyhoo, thanking you kindly. :smilehuh:


Battle of the Pelennor Fields

Made by 1 guy, has 13 Factions, 75+ Heroes, 150+ different units and 200+ Special abilities.

 

http://www.moddb.com...pelennor-fields


#3 Kwen

Kwen

    Vileartist

  • T3A Staff
  • 4,865 posts
  • Location:Korea I wish
  • Projects:It'sa secreeet
  •  T3A's First N00b
  • Division:BFME
  • Job:T3A Expert
  • Donated

Posted 03 August 2015 - 11:00 PM

It can be surprising how many blatant errors the game's debug/crash system misses upon launching, only to encounter later on while the game is running. Out of curiosity, did you use the unit that had a duplicate experiencelevel in your test? I'm wondering if perhaps it would trigger a game.dat crash. If it does then that is valuable knowledge.


                           https://www.twitch.tv/vileartist - Yes shameless self-promotion

          ----------------------------------------------------------------------------------------------------------------------

                            "Old modders never die, they just fade away" ~ Hostile


#4 Titan Cronus

Titan Cronus

    Do unto Others...

  • Members
  • 693 posts
  • Location:Ireland
  • Projects:The Battle of the Pelennor Fields Mod.

Posted 04 August 2015 - 12:46 AM

Aye, its well surprising just how many bugs just slip by.

 

Yes, I did use the unit and it didn't cause any crashes. That's what took me so long to find it. I thought everything with it was perfect. In the end, I just went through every file that was modified today, looking at every piece of code I used. I edit a LOT of files today so it took bloody ages and of course, I didn't think to look in the experiencelevels ini till I had been through everything else. :facepalm:


Battle of the Pelennor Fields

Made by 1 guy, has 13 Factions, 75+ Heroes, 150+ different units and 200+ Special abilities.

 

http://www.moddb.com...pelennor-fields


#5 Kwen

Kwen

    Vileartist

  • T3A Staff
  • 4,865 posts
  • Location:Korea I wish
  • Projects:It'sa secreeet
  •  T3A's First N00b
  • Division:BFME
  • Job:T3A Expert
  • Donated

Posted 04 August 2015 - 01:04 AM

We have a saying in the military, "KISS" which translates to "Keep it simple, stupid!". This also applies to modding. Edit a few things and test! It's tedious how often you need to test, but it saves you from having frequent problems. :p


                           https://www.twitch.tv/vileartist - Yes shameless self-promotion

          ----------------------------------------------------------------------------------------------------------------------

                            "Old modders never die, they just fade away" ~ Hostile


#6 Titan Cronus

Titan Cronus

    Do unto Others...

  • Members
  • 693 posts
  • Location:Ireland
  • Projects:The Battle of the Pelennor Fields Mod.

Posted 04 August 2015 - 01:30 PM

ha ha, I like that.

 

Yea, I was doing that to begin with but then got to confident and got carried away with myself.  :facepalm:


Battle of the Pelennor Fields

Made by 1 guy, has 13 Factions, 75+ Heroes, 150+ different units and 200+ Special abilities.

 

http://www.moddb.com...pelennor-fields


#7 Lauri

Lauri

    Let us remember foREVer

  • Hosted
  • 10,419 posts
  • Location:Norway
  • Projects:'The 4th Age' and 'Shadow and Flame'
  •  The very worst T3A Team Chamber Member

Posted 04 August 2015 - 08:25 PM

That's how I used to mod. Confidence high, plow away! I had coded for many a years by then, so I hardly ever ran into bugs. Still, KISSing the code is important. Anytime I tried to do something that was new or rare territory for me, I KISSed it, one step at a time. Any bug I encountered was luckily in the start, rather than a random game.dat bug mid-game.

 

However, when you do encounter a bug mid-game, try to find the source. The best tip I can give is to play alone (no AI) as a faction (take the one you suspect first). Mod in 30x faster buildspeed and have a ton of money to speed up the process, along with 30x faster experience gain (so heroes level up to rank 10 by killing two goblins). Then build one thing at a time. First a hero, then another, then another. Try attacking creep on the map, with one at a time. Use all abilities. Pay attention. Does the game crash when your hero is hit? If that's the case, something's wrong with the armor code. Any so on, you get the idea. Try units too on this method, along with special powers.

You can also speed up the progress by using the AI, but having all of you be the same faction. It does increase the chance to find the faulty faction, but it's harder to know why it crashed. So you might try to use AI first, then remove it and play alone when you figure out which faction has the fault.


Shadow and Flame BETA 0.6 RELEASED - Link


#8 Titan Cronus

Titan Cronus

    Do unto Others...

  • Members
  • 693 posts
  • Location:Ireland
  • Projects:The Battle of the Pelennor Fields Mod.

Posted 08 August 2015 - 02:20 PM

Only done it again! What... an... eejit! I was even doing tiny edits at a time. I need protection from myself! :facepalm:


Battle of the Pelennor Fields

Made by 1 guy, has 13 Factions, 75+ Heroes, 150+ different units and 200+ Special abilities.

 

http://www.moddb.com...pelennor-fields





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users