Happy Thanksgiving to everyone.
One of my favorite routines is one that gives you a detailed history of the player that is color coded, as in this example:
http://www.sim2005.com/1970/LA_HIS_L...nderson_I.html
However, in my 100 year simulation, we rename players and my program does not like that. The reason is this: Lets say a new guy comes up in 1965. His name is Joe Smith. In 1967, I rename him to Jim Kiss. Some parts of my program will not see anything before the renaming as him.
Example. When you index, if finds Joe Smith in 1965 with a p#### of 1000. It looks in 1966 at player #1000 and sees that it is Joe Smith. So, it assumes it is the same guy. Now it looks in 1967, but player 1000 is now Jim Kiss. So, it assumes that Joe Smith has retired. Not too many problems now though, but since this guy was a #1 draft, it will show Joe Smith and not Jim Kiss as #1 draft. Most of my functions will still work, but the one mentioned above will not.
What would be perfect, if when you rename it in OOTP, if it would go back and rename all of the references to Joe Smith to Jim Kiss. This would solve a lot of headache. I do not anticipate a patch anytime soon to do that, so I have to figure out a way.
At first I thought I could write a search and replace option to do this. But then I thought, you know, I bet there are a ton of free programs to do this for me. So far, I have not found any, but I just started searching. I did find one for 25 bucks, but the shareware worked, nicely, but only did 5 at a time, so I had to keep re-opening the program and do it again to do the above sample. Once I changed them all, my routine worked fine.
But, anyways, I think I may go ahead and write the routine, as I would not have to check every single file. I would only have to check the team prospects, leaderboard, teamsheets, etc. I would have to check the box scores and pbp, if they existed. Even search through them all, it would be no big deal. The big deal would be backing up the files before this was done. If you used it to search for HTML and replace it with SMITH, you are going to have a mess. The also only big problem is the actual HTML player files. It lists the name twice on there, once as Jim Smith and the other as Jim "Horseface" Smith. The search would have to be able to find that. No problem there, as I already do that. I can easily remove the nickname, and put it back. The other problems are for instance in the box scores, it shows J. Smith instead of Jim Smith. What if there is a Joe Smith? Well, no real problem, as if there is a link with the name, then I can check to see if it is player 1000. So, as you can see, it is not 'that easy'.
The other MAJOR problem is John Smith. What happens if there is two John Smiths. Well, the only way I could make it work is to have it display a smidgeon of the page, so you could determine if it is indeed the player you want to change. So, the routine would have to search and maybe show you something like this:
Found 'JIM SMITH is drafted by Baltimore and signed for bla....", Team23.html
With a link to open that HTML page. Once you view it, you can then click REPLACE and poof, it does. Also, there would be a BACKUP button there, so you could back that file up before hand (unless you had clicked BACKUP ALL)
The backup would be a folder you designate, and inside it would be a ALMANAC folder that I would create. Inside it would be all the folders/files that were replaced. So, it would be easy to restore things back to the way they were.
Any thoughts?