Some problems you just can't search on. Here are some I wish were more searchable and this blog is my attempt to make that happen.
Tuesday, December 02, 2008
KTT: Damage Meter AoC Combat Log Processing
My core features were stable on my last release and I have watched it from a distance as people continue to download it. I can't it does not have bugs and many of my newer features are more proof of concept that show what can be done.
How did I gather dps stats?
The first big roadblock was the fact that Age of Conan did not have true mod support. It did however have a feature I could use to my advantage. AoC would generate a plain text file in realtime that contained the combat log. Every attack, heal, buff, debuff, and xp gain was recorded in that file. That one feature gave me a world of options and features that could be implemented.
Getting the correct file:
The log file was located in a sub folder within the AoC directory. During install, a registry key is set to the install path of AoC. The logs were named in such a way that an alpha sort would get me to the correct ime. On first scan of the directory, I grab the logical file and set a marker to the end of it. I start at the end of the file to exclude old stats. I assume that starting KTT is when stat collection should start.
I also add a watch on the folder for new files getting created. There are times when KTT will be running already before the logfile gets created. If I did not watch for new files it would be stuck on the old one and never collect any stats.
Processing the log:
Twice a second I reopen that file. From the marker to the end of the file, I add every plain text line into a queue. The marker is updated with the end of file and the file is closed. I had to open the file in a read only non locking stream so it did not cause issues with AoC writing to that same file. I used the queue so I could collect the data as fast as possible and get that file closed as fast as possible.
I would then work that queue with regular expression to pull out the various values and actions. I ended up with a fairly complicated regex query that did most of the work for me. I found 4 distinct sentence structures that indicate source, target, action, and a value. AoC made the combat log in sentences that were proper English that even reflected 2nd person when needed. While it sounds nice when read out loud, it creates a lot more work when writing a parser. So the regex ended up to be 4 page widths long but I didn't have to post process any of the values.
Once each line was processed into an action object, it was then placed on another queue. I used a queue her so I could multi thread the log reading/parsing away from the rest of the application. As I work this queue I would pass the object off to the plugin framework. The damage meter plugin would flatten that stats as it received them. When calculating total damage, I just add the damage on the fly so the reporting side can just report the precalculated total. (vs summing the damage every time I want to report it). I did this for any stat that I could think of.
Because I compressed the stats like this, I could keep the queue clear of actions. The point of this is my memory usage is only as wide as the number of stats I'm recording and not as large as the log file. During a large raid, the log file can grow to very large sizes very quickly. While KTT will jump in size very quickly as it sees a stat for the first time, as that stat is repeated over and over many times in the log, it will not take much additional memory.
In closing:
I may do little write ups on other features of my mod (or its potential) later. I wrote this for other mod writers. To show them that with very simple things and ideas you can do some very cool things. While I may not have described the best way to do something, it still worked very well for me. The mod is listed as KTT Damage Meter, KoS, Timers, & Sounds over at curse.com.
Monday, November 17, 2008
Antivirus 2009 Protection Scam pro-scan-online
I was on my work machine and I received this pop up warning me about spyware. This kind of shocked me because the sites I visit at work are few and are work related. Not the type of sites that usualy have this type of advertising. Now that I think about it, I may know the site. If I am right, its a 3rd party add doing it so any site you trust could be doing it.
I run several monitors and could see a session of IE running as small as it possibly could off to the right. A place that would be off screen for most people. Once I closed the pop up message, I saw it open a full window page that did a fake scan of my system. It indicated that several errors were found and even gave the names of a few viruses. As an IT security professional, I know how to keep my system clean and knew the report that it gave me was staged and false.
Clicking anywhere within the window (like the fake red X or cancel button) started downloading a file. On older web browsers it prabably would have just ran the program, but my version of IE gave me the option. You can either save it or run it. I pray that none of you ran it. Don't even save it. Your best bet is to close IE and end your session. Then log off or reboot.
I did not get infected by it, but I can easily see how the average person would. I work in IT and have a good eye for stuff like this. I also know the average user and this prays on them. I also know several people that have gotten trapped by this. I included some screen shots from the site and a few links where people were talking about it.
The URL for me was pro-scan-online.com but with a scam like this, I expect them to have lots of different sites set up. The file name was A9installertest_77024202.exe.
Here are some other people running into this same thing:
http://forums.vnunet.com/thread.jspa?threadID=146114
http://forum.joomla.org/viewtopic.php?f=267&p=1484262
http://loscompanion.com/forums/index.php?topic=5473.0
From reading a bit, its called the A9 Installer virus. I think its more crapware than a virus, either way avoid it.
Sunday, April 13, 2008
Windows cannot install required files. Make sure all files required for installation are available, and restart the installation. Error code: 0x800703
My first guess was to remove a stick of ram. I have heard that before and I was at 4G with the 2 sticks. That did not help this time. I ran the memory tests and everything was ok. I left that second stick out while doing the rest of my tests.
I looked for the error code and I found a KB article (KB930984) that described my exact problem. It indicated that my firmware on my DVD drive was causing the issue. Either update the firmware or copy the files to the disk. I copied all the files to my C: and rebooted. I let it boot from the hard drive and ran into the same issue. I saw another site suggest that the DVD drive needed to be the slave on the IDE cable. Changing the jumper didn’t fix that either. I disconnected the DVD drive and the installer required that I had one.
I thought that was odd. I had an old DVD drive that windows would see but could not see any disk inserted. I set it up and started the install over. It still complained about the DVD drive. After placing a copy of all the files and the main disk and booting from it, the install would still look for the install files on the DVD. I still had the install disk in the drive during some of my tests. That would explain me still getting the error when I thought I had ruled the DVD drive out.
After some more searching, I found the solution. Installing Vista from Hard Disk, USB Disk or Memory Stick. I selected the repair option instead of install after reading that. Ignored the drive selection and started the command prompt. I ran the fallowing commands:
c:
cd /boot
del bcd
bcdedit /createstore
cd ../sources
setup
The install went smooth after that. After the install finished, I reformated and installed Vista 64 bit. I was using my 32 bit disk because its a known good one. I was having issues so I wanted to eliminate variables as much as I could.
I copied all the CD files to the C: again but it failed to boot. I booted to the DVD but droped to a command line and ran the install off the hard disk. I did not have any other issues with the rest of the install. I even did that last install with both sticks of ram.
BIOSTAR TForce TP35D2-A7 with Intel Core 2 Duo E8400 requires bios update
Intel Core 2 Duo E8400 Wolfdale 3.0GHz 6MB L2 Cache LGA 775 65W Dual-Core Processor
BIOSTAR TForce TP35D2-A7 LGA 775 Intel P35 ATX Intel Motherboard
The power supply would turn on, all my fans would spin up, and then they would all spin down. Power would recycle and it did the same thing over and over. I looked to the manual for the TP35D2-A7 and it indicated 2 LED status lights were on the board. Neither one lit up and that indicated unusual mother board or CPU issue. In the over clocking section of the manual it indicated the power would cycle like I was seeing when clock settings did not work with the CPU.
I was reading on the Biostar page and it does not list the E8400 as a supported processor. In the FAQ they had a question on support for the 45nm processors and it indicated a bios update was needed. I saw this before I made my purchase. When I ran into this issue, I expected that I needed to do a bios update. The catch is if you need a supported processor installed to update the bios. If this was my first build and all I had was the E8400, I would have been dead in the water. That was my situation.
I work in an IT department so I took my computer in with me the next day. I used a processor from a work machine to get it to boot up and flashed the bios. I placed the E8400 back into the mother board and it booted up without issue.
To sum it up, you will need a bios update for TP35D2-A7 if you are going to use an E8400 with it and you need a working processor to update the bios. I was using the E8400 but the same should hold true for the E8200.
Saturday, March 29, 2008
Tortage: Age of Conan Database
At this point the game does not support mods. Once they add that ability I believe I can write some data mining mods from inside the game that will automate the process. I bet I can data mine it from the back end, but its so much easier when the program makes the API calls available to you. The advantage the in game mod can provide is location tracking when they pick something up or complete a quest.
Until the support for mods is available I will work on other related projects. One of my first ones is a talent calculator. Someone makes one for every game. This time it may as well be me.
Work has already started. I have purchased the domain name tortage.com and have a server up an going. A place holder page is in place so search engines can start indexing it. The server is a low end Linux box at the moment. When it starts to generate traffic, I plan to find a good host. I would rather save the cost of hosting it for now.
Some of you are asking why the name Tortage. Tortage is the starting are in Age of Conan. Your first 1-20 levels in AOC are spent in that area. It the place where you are introduced to the game and given the information you need to get started. That's the same idea behind the website.
*DNS setting are still getting adjusted, so its possible the site will be dark for the next few days.
Tuesday, March 25, 2008
Internal error occurred on the report server. See the error log for more details. rsInternalError Get Online Help EXECUTE permission denied on object
An internal error occurred on the report server. See the error log for more details. (rsInternalError) Get Online Help EXECUTE permission denied on object 'sp_verify_job_identifiers', database 'msdb', schema 'dbo'.
It looks like a permissions issue. After some searching on the error I found a post over at Karim's Blog with the solution. He provided the a script that adds execute permissions to several objects in the database.
Here is his script:
USE master
GO
GRANT EXECUTE ON master.dbo.xp_sqlagent_notify TO RSExecRole
GO
GRANT EXECUTE ON master.dbo.xp_sqlagent_enum_jobs TO RSExecRole
GO
GRANT EXECUTE ON master.dbo.xp_sqlagent_is_starting TO RSExecRole
GO
USE msdb
GO
-- Permissions for SQL Agent SP's
GRANT EXECUTE ON msdb.dbo.sp_help_category TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_add_category TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_add_job TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_add_jobserver TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_add_jobstep TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_add_jobschedule TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_help_job TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_delete_job TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_help_jobschedule TO RSExecRole
GO
GRANT EXECUTE ON msdb.dbo.sp_verify_job_identifiers TO RSExecRole
GO
GRANT SELECT ON msdb.dbo.sysjobs TO RSExecRole
GO
GRANT SELECT ON msdb.dbo.syscategories TO RSExecRole
GO
Saturday, February 23, 2008
Custom RDP Solution Part 3 (RDX)
Initial testing only uncovered minor issues. After those were resolved we deployed it to a few of our users that connect to all of our terminal servers. I am using it when I VPN into my work machine. Several high traffic machines were secretly changed over. Not only was the change over smooth, the users had no issues with it.
We are ready for production. As we rebuild or deploy new machines, my new client goes out with them. Once I have about 10% deployment penetration, I plan on pushing it out domain wide with group policy.
Thursday, January 24, 2008
Tweaking Vista
I recently made the jump to Vista. I feel like I now have it tweaked and performing reasonably well. I can sit here and type to the sound of my keyboard keys and not to the grinding of my hard drive. Vista spent a lot of recourses just being vista and not doing anything useful.
I like to pull up task manager and see that CPU usage dance between 0% and 2% as I type this. I have a little blog authoring tool open and IE displaying my last search behind me. I also trimmed the memory usage down, but I cant get it anyplace close to XP or server 2003.
Most of my tweaking was done by disabling services to features that don't add any value. I have disabled everything possible that does not impact my use of Vista. I have some things enabled that I would remove if I did not VPN regularly. Here is my list of running services that I felt are required for a stable functioning computer.
Wednesday, January 16, 2008
get Outlook 2007 work with Lotus Domino server using DAMO
That left us with having to use only Lotus Notes. For Outlook 2003 I was able to use Outlook 2003/2002 Add-in: Notes Connector from Microsoft. When Outlook 2007 was released, Microsoft never updated that addon. IBM also did the exact same thing. The IBM addon is called Domino Access for Microsoft Outlook . After some digging, I was able to get the IBM DAMO connector to work with Outlook 2007.
The first question is where do I find or download the DAMO? The simple answer is that you get it from your server administrator. You cannot download it as an individual component. You have to install a copy of the Lotus Domino server to get the DAMO installer. I have no clue why IBM does not provide it as a standalone download. I also do not see it hosted anyplace else. I am reluctant to host it myself because of that.
So to get your hands on it yourself you will have to download a trial copy of Lotus Domino 8 (or whatever the current trial is) from the Lotus downloads page. This does require registration, but its fairly painless. When you do the install, you can deselect everything except DAMO. I somehow lost the DAMO installer when I tried it, but was able to do a computer search to find it.
Once you do the install, you must add the install location (%ProgramFiles%\DominoForOutlook) to your Path variable in environmental variables. Make sure that all other lotus locations in that path variable are after the one you just added. I did see a registry key to check. Mine was set to the correct value by default.
computer\hkey_current_user\software\microsoft\office\outlook\addins\inotesoutlookaddin.addin
Change LoadBehavior to 3.
The next issue you will run into is missing emails or messages that don't replicate into outlook. By default, you will only see the last 90 days of messages and will be limited to 200M of email. In the Outlook tools -> options -> Domino Preferences you will find a replication section. Bump it up to 365 days and 1600M. Then close out of Outlook and reopen it. Once it finishes replication, go back in and lower the number of days in those options. If you leave the number at 1 year replication will be slower day to day.
So far it has worked very well. I am still looking into an issue where a message with a corrupt message body does not show up in Outlook but does in Lotus.
Sunday, January 13, 2008
MySims load times are killing me
I recently got a Wii and now have MySims. I kind of like how I can use the blueprints and just crank out things, but have the option of freedom.
I like being able to make some very creative items.
At the same time, the amount of time spent loading everything is killing the game for me. I can understand some loading. Every time I enter a building or leave a building it has to load something. I expect that loading.
The place where it gets under my skin is the loading in the menu screens. Every time you check your back pack, or tasks, or friends, or blue prints it has to load them. These are simple heads up display items that you would expect to be very responsive.
Not only does everything have to load every time the display changes, extra steps are added that cause more loading time.
Here is an example. If I want to build something, I have to go to my shop. Before the shop loads, I am asked what I want to work on. I make a choice and then have to wait for my shop to load. Lets say I am done with that item and want to work on a second. I have to leave the shop, wait for the world to load, enter the same shop I was just in, make my choice, and wait for the shop to load again.
Several of the menu items force you back to the main menu requiring you to load the submenu again if you want to look at a different option.
This is a good game. But when I am working fast, I spend 1/3 of my game time looking at the loading screen. I wish that was an exaggeration.
I get the feeling the framework is too bloated and overused. It sounds like other recent Sims games suffer in the same way. I would hope they clean up there code base before reusing it in another project.
Friday, January 04, 2008
Why does windows live take so long to install?
I saw Microsoft released a blog writing tool as a windows live app. I decided to try it at work and at home. The installer has one step where it checks for existing windows live apps. It bothers me that Microsoft has a dozen or so apps, yet it spends a lot of time looking for them.
It takes longer for the installer to look for those 12 apps than to do the rest of the install.
I can only guess what they are looking for, but I suspect that step is just mislabeled. Sometimes its the small details that give you uneasy feelings.
Thursday, January 03, 2008
RDX Testing
I am calling my custom RDP program CODTSC and using RDX as the file association.
Initial development is complete and I have finished my personal testing. I put together a deployment package for my coworkers. We set up a sample RDX file with a special config tool that I also built for them.
At the end of the day we deployed it to a single user that uses RDP to connect to 5 different sessions. That user has RDP files provided for them. In the morning I will see how seamless the deployment went once the user gets a chance to use it.
Ideally this will work at least as good as mstsc and not introduce any new problems. The user does not know we made the switch. They will see it look a little different when connecting, but after that it should not change any thing for them.
Wednesday, January 02, 2008
Custom RDP Solution Part 2
The bigest issue with this is the fact that single sign on is not supported. So I have to get creative to work around that limitation. I think with the use of web services and a little social engeneering on the part of app, I can recreate the effect.
At some point I will have to collect the password from the user and store it in a save place. Its not that hard to create a login screen that looks like the one they currently see. If the username matches the username they currently logged in with, Its save to save the password to the account. I would prabably encrypt it to a personal network share that every user has. This allows it to roam with them.
The bigest issue is when the wrong password gets entered or its changed after its saved. I will need a process to verify the account information. When authentication fails when making a rdp connection, they user is prompted on the remote end for the correct information. My application can not tell from the conneciton if the details are correct or not.
I am thinking about using a webservice that will serve as my authentication check. I know I can load my webservice request with login information I get from my user. So if it authenticates, the information is good.
In the end, I think it will work. I might find a simpler solution than using a webservice. I might use it to create a central connection log of all rdp trafic.