Jump to content

.dat exporter and importer (will allow editing a dynasty)


tywiggins

Recommended Posts

My hypothesis as to what i did wrong!

Editing exported Dat files on MVPEDIT, as we know, is only possible if we group them together in conjunction with other supplamenting DAT files.

I think my error is, and i hope someone can conform this, is that when i imported the Exported dat files, the supplamenting (non exported) Dat files affected the game as they where present in the same folder.

Before i would import dat files in a seperate folder away from supplamanting dat files. So i'm thinking that maybe the IMPORTING tool imported not only exported dat files back into the game, but supplamenting files as well. Because the information in supplamenting DAT files is different (in terms of roster information) than those in the game, I'm guessing this is causing screwed up stats.

I guess the question should be, does the importing tool import only the 4 dat files, or will import all dat files found present within the same folder.

Link to comment
Share on other sites

  • Replies 538
  • Created
  • Last Reply

My hypothesis as to what i did wrong!

Editing exported Dat files on MVPEDIT, as we know, is only possible if we group them together in conjunction with other supplamenting DAT files.

I think my error is, and i hope someone can conform this, is that when i imported the Exported dat files, the supplamenting (non exported) Dat files affected the game as they where present in the same folder.

Before i would import dat files in a seperate folder away from supplamanting dat files. So i'm thinking that maybe the IMPORTING tool imported not only exported dat files back into the game, but supplamenting files as well. Because the information in supplamenting DAT files is different (in terms of roster information) than those in the game, I'm guessing this is causing screwed up stats.

I guess the question should be, does the importing tool import only the 4 dat files, or will import all dat files found present within the same folder.

The latest version of the importer works with 5 files currently. The messed up stats are caused by the reordering of the players in the dat files. (MVPEdit sorts the players by name) The stats files in memory are untouched, but when you import the 5 files I have done, and the players are in a different order, then the stats for any given player may be in the wrong place.

Link to comment
Share on other sites

This is seemingly great work. I have yet to download and fiddle around with it yet. Will the stats bug be fixable?

When i import and export all of the stats files it should fix it. (I believe that the stats in the bstats.dat, lhbstats.dat, and rhbstats.dat should work correctly with the latest version. Basically all of the batting stats except the career stats should work correctly already) I plan to have all of the fielding and pitching stats done by tomorrow morning. I still need to code the importing of rhpstats.dat, lhpstats.dat, careerp.dat. And then I need to test both programs, to make sure that the stats are correct.

There will be a small problem with the minor league fielding stats and MVPEdit. I create 4 fielding stats files: fbstats.dat, fbstatsAAA.dat, fbstatsAA.dat, fbstatsA.dat. Every player has an entry in each file. Since MVPEdit only imports fbstats.dat, the other 3 fielding stats files will not be sorted along with the other .dat files. This will cause the minor league fielding stats to be wrong. But, this is a "minor" problem as the fielding stats do not save from year to year, even for major league players. Hopefully, I can get the author of MVPEdit to incorporate these new files into MVPEdit.

Minor league pitching and batting stats are stored in the hist.dat equivalent in memory. These are stored in a different way, so these stats should not be affected by the reordering of players by mvpedit. I haven't yet figured out everything about the hist.dat equivalent in memory, so you won't be able to edit minor league pitching and batting stats yet.

Link to comment
Share on other sites

Everything works great so far except for one thing. After importing the database files back in to the game, there are always 6-10 players from MLB teams that end up in the FA pool. It's always Berkman, Doug Davis, and Jose Reyes, among others. I made sure that no teams have more than 3 lrp's, etc., but it still happens. Any ideas?

Link to comment
Share on other sites

Everything works great so far except for one thing. After importing the database files back in to the game, there are always 6-10 players from MLB teams that end up in the FA pool. It's always Berkman, Doug Davis, and Jose Reyes, among others. I made sure that no teams have more than 3 lrp's, etc., but it still happens. Any ideas?

Those players wouldn't happen to be on the disabled list before you exported, would they? I just realized that players on the disabled list would become free agents. I'll get to the disabled list soon.

If the players weren't on the disabled list before you exported, could you please email the .dat files to tywiggins@hotmail.com ?

Link to comment
Share on other sites

I just updated to v0.19. fbstats.dat, fbstatsAAA.dat, fbstatsAA.dat, fbstatsA.dat, career.dat, pstats.dat, rhpstats.dat, lhpstats.dat, careerp.dat are now imported and exported.

Next, I'll work on player happiness, injuries, energy, contract level, contract role, and the disabled list.

Link to comment
Share on other sites

I am having trouble with crashing on the importing. The exporting and team changer work fine. Here is what I am trying to do.

1. I sim the 2005 season and get to the start of the 2006 season, simming through free agency.

2. I export the files and replace them with files from UR 6.3 plus.

3. When I import, I get through the first three, then I get a fatal error and program had to close message.

Any thoughts? I had the earlier versions working and I do have the proper .net framework.

Link to comment
Share on other sites

I am having trouble with crashing on the importing. The exporting and team changer work fine. Here is what I am trying to do.

1. I sim the 2005 season and get to the start of the 2006 season, simming through free agency.

2. I export the files and replace them with files from UR 6.3 plus.

3. When I import, I get through the first three, then I get a fatal error and program had to close message.

Any thoughts? I had the earlier versions working and I do have the proper .net framework.

I think I know what the problem is. I think it's because you're importing less than 3250 players. The code for the importer assumes that there will be 3250 players. I can see why this would cause an error at the beginning of importing pitcher.dat. It should be easy to fix.

I'm planning on having a new version done by tomorrow morning, so I'll go ahead and make the changes that will allow you to import less than 3250 players.

Link to comment
Share on other sites

just updated to v0.20, extra.dat is now imported and exported -- extra.dat includes: energy, contract type, injury type, injury time, disabled list slot, day put on disabled list, unknown1, and unknown2. In my next version it will also include pitcher's current stamina. I thought I could calculate this from the energy and pitcher's max stamina, but I was wrong.

Energy is the player's energy percent (0 to 100)

Contract type is what type of contract the player has (0 to 35) 0 is MLB Ace

Injury Type is what type of injury the player has (0 to 49) 0 is not injured; 49 is suspended.

Injury Time is how many more days until the player is healed (0 to 255)

Disabled list slot is which slot on the disabled list the player is in (-1 to 504) -1 is not on disabled list. Each team has 2 slots for the 15 day DL and 2 slots for the 60 day DL. The slot numbers for the Angels of Anaheim are 0,1,2,3.

Day put on disabled list is (-1 to 65535) -1 means not on DL. Day 0 is approximately January 1, 1948; Day 65535 would be somewhere in July of 2127.

I couldn't figure out some of the bits in the attrib.dat in memory. I know some of these unknown bits relate to happiness, but I wasn't able to determine what each did, so I just saved them as unknown1 and unknown2. Some may be important, some might not be.

unknown1 (0 to 15)

unknown2 (0 to 31)

And like I said earlier, in the next version, I will also include pitcher's current stamina in this file.

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

I haven't tested this yet, but I believe that extra.dat should import correctly even if MVPEdit reorders the players in the other .dat files.

In the next version, I will also import the minor league fielding stats in the same way.

From my tests so far, player happiness seems to be unchanged after an export then an import. The same for energy level, and contract type. Injury Type and time I only tested with one player, but it was correct. Same goes for DL slot and DL day.

Also I made it so that you can import less than 3250 players. I just added in a few lines. Right now it fills up the remaining spots with 0's, so it's not perfect. (That creates a bunch of 57 year old starting pitchers to fill the extra spots. Later on, I think I'll make these hidden players.)

Link to comment
Share on other sites

This seems to be working very very well.

Here is what I did. I simmed the 2005 season, all the way through spring training of 2006. At the very start of the 2006 season I exported the game files, and replaced them with Ultimate Rosters. Everything seemed fine (it created the extra players which were perfect, since they had no name or rating they were dropped to the bottom). The correct 2005 stats showed up, and by putting the 2006 schedule in for 2006, I bascially started at opening day 2006. Then I simmed the 2006 season and checked for any bugs or crashes. Everyone aged properly and all seemed fine. If someone is going to try this to start their season in 2006, just make sure you have the proper contracts for players that were not signed this year. For example, in ultimate rosters new signed players have their correct length (ie Billy Wagner) but incumbents do not (Carlos Beltran should be 6 years as of 2006, not 7). This is obviously not a problem with the importer or UR, just a matter of taste if you try this method to have the calendar read 2006.

The only issue I saw was that in the 2007 retiree class, Orlando Hernandez and Bartolme Fortunato had almost no ability and retired because of it. I didn't check if these guys were possibly DLed in the spring training prior, so I will check that. I also noticed a draft pick named R. Langerhans. He was a pitcher with almost no ability taken in the first round of the draft. I did not notice if the real Ryan Langerhans was still on the Braves. I will do more tests, but so far this is working great. Thank you so much for this.

Link to comment
Share on other sites

You're welcome. And thanks for testing it out.

Last year's stats loading correctly at the beginning of the 2nd season does bring up another issue.

Apparently, in the 2nd season, last year's stats are where my program expects the current year's stats to be. So, I think I will add last year's stats to the exporter and importer, since it won't take much additional work.

Link to comment
Share on other sites

Here's the list of injuries by number

1 = A Pulled Hamstring

2 = A Pulled Groin

3 = A Sprained Ankle

4 = A Strained Left Forearm

5 = A Strained Right Forearm

6 = A Strained Lower Back

7 = A Strained Left Ribcage

8 = A Strained Right Ribcage

9 = An inflamed Left Shoulder

10 = An inflamed Right Shoulder

11 = An inflamed Left Elbow

12 = An inflamed Right Elbow

13 = A Finger Blister

14 = A Dislocated Finger

15 = Shin Splints

16 = A Sprained Wrist

17 = A Minor ACL Strain

18 = A Minor PCL Strain

19 = A Minor MCL Strain

20 = Minor Wrist Tendonitis

21 = A Minor Meniscus Sprain

22 = A Minor Concussion

23 = A Bruised Ankle

24 = A Fractured Nose

25 = A Torn Left Shoulder Muscle

26 = A Torn Right Shoulder Muscle

27 = A Strained Right Hip Flexor

28 = A Strained Left Hip Flexor

29 = Major Wrist Tendonitis

30 = Tendonitis of the Elbow

31 = Tendonitis of the Knee

32 = Tendonitis of the Achillies

33 = A Fractured Right Knee

34 = A Fractured Left Knee

35 = A Fractured Toe

36 = A Fractured Finger

37 = A Fractured Ankle

38 = A Hernia

39 = A Concussion

40 = A Fractured Hand

41 = A Torn Rotator Cuff

42 = A Fractured Leg

43 = A Fractured Arm

44 = A Separated Shoulder

45 = A Torn ACL

46 = A Torn MCL

47 = A Torn PCL

48 = A Torn Knee Meniscus

Link to comment
Share on other sites

Here's the list of injuries by number

1 = A Pulled Hamstring

2 = A Pulled Groin

3 = A Sprained Ankle

4 = A Strained Left Forearm

5 = A Strained Right Forearm

6 = A Strained Lower Back

7 = A Strained Left Ribcage

8 = A Strained Right Ribcage

9 = An inflamed Left Shoulder

10 = An inflamed Right Shoulder

11 = An inflamed Left Elbow

12 = An inflamed Right Elbow

13 = A Finger Blister

14 = A Dislocated Finger

15 = Shin Splints

16 = A Sprained Wrist

17 = A Minor ACL Strain

18 = A Minor PCL Strain

19 = A Minor MCL Strain

20 = Minor Wrist Tendonitis

21 = A Minor Meniscus Sprain

22 = A Minor Concussion

23 = A Bruised Ankle

24 = A Fractured Nose

25 = A Torn Left Shoulder Muscle

26 = A Torn Right Shoulder Muscle

27 = A Strained Right Hip Flexor

28 = A Strained Left Hip Flexor

29 = Major Wrist Tendonitis

30 = Tendonitis of the Elbow

31 = Tendonitis of the Knee

32 = Tendonitis of the Achillies

33 = A Fractured Right Knee

34 = A Fractured Left Knee

35 = A Fractured Toe

36 = A Fractured Finger

37 = A Fractured Ankle

38 = A Hernia

39 = A Concussion

40 = A Fractured Hand

41 = A Torn Rotator Cuff

42 = A Fractured Leg

43 = A Fractured Arm

44 = A Separated Shoulder

45 = A Torn ACL

46 = A Torn MCL

47 = A Torn PCL

48 = A Torn Knee Meniscus

Actually you have #15 and #16 switched

This list is correct:

0 = No Injury

1 = A Pulled Hamstring

2 = A Pulled Groin

3 = A Sprained Ankle

4 = A Strained Left Forearm

5 = A Strained Right Forearm

6 = A Strained Lower Back

7 = A Strained Left Ribcage

8 = A Strained Right Ribcage

9 = An inflamed Left Shoulder

10 = An inflamed Right Shoulder

11 = An inflamed Left Elbow

12 = An inflamed Right Elbow

13 = A Finger Blister

14 = A Dislocated Finger

15 = A Sprained Wrist

16 = Shin Splints

17 = A Minor ACL Strain

18 = A Minor PCL Strain

19 = A Minor MCL Strain

20 = Minor Wrist Tendonitis

21 = A Minor Meniscus Sprain

22 = A Minor Concussion

23 = A Bruised Ankle

24 = A Fractured Nose

25 = A Torn Left Shoulder Muscle

26 = A Torn Right Shoulder Muscle

27 = A Strained Right Hip Flexor

28 = A Strained Left Hip Flexor

29 = Major Wrist Tendonitis

30 = Tendonitis of the Elbow

31 = Tendonitis of the Knee

32 = Tendonitis of the Achillies

33 = A Fractured Right Knee

34 = A Fractured Left Knee

35 = A Fractured Toe

36 = A Fractured Finger

37 = A Fractured Ankle

38 = A Hernia

39 = A Concussion

40 = A Fractured Hand

41 = A Torn Rotator Cuff

42 = A Fractured Leg

43 = A Fractured Arm

44 = A Separated Shoulder

45 = A Torn ACL

46 = A Torn MCL

47 = A Torn PCL

48 = A Torn Knee Meniscus

49 = Suspended

Link to comment
Share on other sites

I am having trouble still getting this into mvpedit, it says that there is error 3022 and basiclally it says the changes could not be made because there are duplicate values. This is in MVP Edit after having copied in the extra .dat files from /data/database. If you need the full error please ask, I will be glad to type it out

Link to comment
Share on other sites

I did get that same error using the extra files to try and edit using MVP Edit.

I did however have no problems updating the files in notepad, or doing what I said earlier, where I just imported the entire Ultimate Roster set after simming the 2005 season. Both of those seemed to work just fine, albeit in very limited testing.

Is there any way to update team records? It would be amazing to sim up to say tomorrow's games on the 2006 schedule, then update the team records, maybe update some key performer stats (such as Pujols, Shelton, etc.) and then continue with the current major league season. We would even be able to DL players properly. Just a thought.

Link to comment
Share on other sites

I did get that same error using the extra files to try and edit using MVP Edit.

I did however have no problems updating the files in notepad, or doing what I said earlier, where I just imported the entire Ultimate Roster set after simming the 2005 season. Both of those seemed to work just fine, albeit in very limited testing.

Is there any way to update team records? It would be amazing to sim up to say tomorrow's games on the 2006 schedule, then update the team records, maybe update some key performer stats (such as Pujols, Shelton, etc.) and then continue with the current major league season. We would even be able to DL players properly. Just a thought.

Yes, you will be able to update the standings. That is in the next file that I will get to.(tstats.dat)

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

I got that same error that you and forte14 got when I import the files that have the "Zero players". What you can do is delete all of the players with playerid of 0 from all of the files.(They're all at the end) You can then import the files with MVPEdit. This error is because playerid is the primary key in the database in MVPEdit, meaning there can be no duplicates. Later on, I'll give each of the "Zero players" a unique playerid. Also, I might not export the "Zero players"

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

I'm getting another error in MVPEdit. (Runtime error '9'. Subscript out of range) I'm using the rosters from the MVP06 mod beta, and for some reason, when I export with my program, Edwin Almonte's name has a lot of extra space after his last name, but, only in the pitcher files. It only does it for him. If I clear the extra space, it works fine in MVPEdit. I'll work on fixing this error.

Link to comment
Share on other sites

This is great stuff. I was able to set up my Reds dynasty with the injured players (LaRue, Wilson, about 15 other minor leaguers) on the DL, for the appropriate times, intead of stashing them on the A-ball team.

Nice find.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.


×
×
  • Create New...