PDA

View Full Version : New Modified Version



slartibartfast
10-05-2003, 03:56 AM
Note This version was developed using .Net 2003, so you need .Net framework 1.1 installed to run it.

- It may be possible to convert the project back to .Net 2002, but i have not tried yet.

<EDIT>
attempt 2 - stupid file size limit gonna try split it using RAR
</EDIT>

<EDIT>
ARG!!! cant upload rar files. Changing the file extension to .zip, you will ned to rename them back to .rar before you can extract them.
</EDIT>


This code is based on Netonims version.

Changes:
1) integrated latest showeq races + bodytypes + con code. + changed code so it doesnt complain about unknown or out of range races + types.
2) Addressed crashing problem on win98 + ME (all drawing now done within a try catch)
3) Converted the Network routines to use non blocking asynchronous reads (doesnt increase frame rate but makes the client more responsive)
4) When using player con colours, a yellow square is drawn arround the spawn so that you can easily tell which spawns are players.
5) Corpses now appear when players or mobs die. White circle for mobs, yellow square for players. (nb player corpse detection is not perfect - but works well for players that have last names)
6) Fixed problem with starting myseq in an unknown zone.
7) map con coulours now automatically update when a player levels (NB players using horses will need to use the override level function)
8) Changes the mob collection to use a hashtable object to make lookups quicker - managed to remove most iterative loops that searched for a given SpawnID.


<EDIT>
Removed attachment, I made a new improved version + created a crap website to host it, get your new and improved version here: Slartibartfast's Crap Website (http://www.angelfire.com/rpg2/slartibartfast/)

Additional Changes:

Modified MySeq server:
1) Fixed horse bug. (requires a new ini file supplied in the archive)
2) Changed the string to int routine so that it can cope with hex values in the ini file. Will now accept hex or decimal values. numbers with a leading zero are treated as hex. Valid formats:

12345 (treated as decimal)
01E240 (treated as hex)
0x1E240 (treated as hex)

Modifications to Client:
1) Improved PC corpse detection. If you are in zone when PC dies it will be correctly identified as a player. - still not perfect for player corpses that exist when you zone in if they dont have a last name. ShowEQ uses religion as its PC detection algorythm so i may have to add that to the packet stream.
2) Corpses now appear grey in list box.
3) I think i fixed the shopkeeper type showing up as unknown.
4) I hope I have fixed the hashtable enumeration error. (It was a rare crash so hard to say for definite)

</EDIT>

slartibartfast
10-05-2003, 03:58 AM
part2 of 4

grrr 60 second post limit, this is fun !!!

<EDIT> Removed attachment see first post for download instructions.</EDIT>

slartibartfast
10-05-2003, 03:59 AM
Part 3 of 4

<EDIT> Removed attachment see first post for download instructions.</EDIT>

slartibartfast
10-05-2003, 04:00 AM
Part 4 of 4

/em Twiddles his fingers whilst waiting for the 60 seconds to elapse.

<EDIT> Removed attachment see first post for download instructions.</EDIT>

showme1
10-05-2003, 03:26 PM
Not working, i think some file is missing. No way you can get it all archived into one file?

slartibartfast
10-06-2003, 04:29 AM
The archive does not include the MagicLibrary.DLL cause it is quite big - copy that accross from your normal MySeq directory

I found a couple of niggling bugs that i need to fix:

1) Corpses dont go grey on listview when they appear.
2) Shopkeepers were coming up type unknown
3) Getting an error in the paint routine
"Collection was modified during enumeration"
- this last one is a bit wierd, im guessing that somehow a packet is arriving mid paint and changing the mob collection - which invalidates the iteration of the mob collection. Not sure how to prevent this so ill probably just stick a try catch round the whole Form1_paint routine. - Or possible only invalidate the map after I have received the whole packet, at the moment i repaint it after processing a partial packet. It doesnt happen very often, but results in the big red cross on the map.

I plan on looking at looking at the horse bug next, but this requires more knowledge about how the horse + mount are related in the eq memory space, guess a trip to macroquest's web site is in order...

Midnight
10-06-2003, 08:48 AM
why split this into 4 files. just make it one and link it please. and having to rename the .zip to .rar is too troublesome. if you want people to use your product, please pack it correctly :) thanks much

TempLoginName
10-06-2003, 01:59 PM
Ok, I have to reply to this:

slartibartfast's MySEQ client is REALLY FREAKING GOOD. I could care less that he breaks it up into 4 files; he's providing a greatly enhanced and MUCH more stable (1.13 crashed like crazy for me) version of the client and he shouldn't have to use his own webspace and link it to do so.

The only bug (other than spelling errors that remain in the options menu that I hex-edited the exe to fix) was that sometimes the little X next to the thumb-tack used on the mob-list becomes a little red X and gives me a recoverable error message (just click continue). But this client is well worth the trouble getting the files and renaming and unpacking.

Please keep releasing your client slartibartfast, I love it.

Old No Name

P.S. - here's a list of stuff I would like to see you do with this.

One, allow for a wave file for each type of alert, currently the wave file only plays when a "hunt" alert mob spawns (which is ok, I want different sounds for "hunt" mobs and "rare" mobs.

Two, add ini entries for the prefix for "hunt", "caution" and "rare" mobs. I hex edit the Prefix to be " []" for all three types, and leave the Suffixes as *H*, *C* and *R* respectively.

Three, see if you can figure out the error/bug I posted. Usually the first time after I run the MySEQ client, after I have the mob-list as my focus, if I press tab, it selects the little X (next to the thumbtack) and it errors (which I can click continue and it keeps working) and the X turns into a red X (like when the map would error, which, by the way, hasn't happened for me with your version ever).

Four, there's a couple spelling errors in the options menu, like Altert. Personally, I just used a hex editor to fix this and capitalize every word in that menu (looks cleaner that way).

Five, is there anyway to have the alerts file correctly remark alert mobs when you select reload alerts? I have to hit F2 after reloading the alerts, and since I sort by spawn time hitting F2 resets all the spawn times. =( Related to this; when I enter a new zone, I have to hit F2 after the zone fully loads to have alert mobs correctly marked (since the moblist laods before the alerts file for that zone loads).

TempLoginName
10-06-2003, 02:21 PM
EDIT
I also added slartibartfast's MySEQ client in a zip file. If you need me to host the file slartibartfast, let me know. Click on the download link to go to a simple webpage with links to both downloads.
EDIT

Here's a font I "created" for use with MySEQ. To install it go to your font folder (easiest to get to through the control panel) then select File, Install New Font...

In MySEQ, select "List Font" and select the font from the list (it should be sorted alphabetically, so it'll be in the M area).

Use it at size 7 or 6.75

Download (http://members.tripod.com/everbot/myseq_font.htm)

It is easy to read and is small so you can have quite a bit of the moblist showing at once.

Old No Name

P.S. - I use MySEQ on the same computer I run EQ from with no performance problem, I just have MySEQ's refresh at 3000 (instead of the default 250). I have 2 monitors; EQ is in a window (1024x768) on the left desktop (which is 1280x1024) while MySEQ is in a similarly sized window on the right desktop (also 1280x1024). I also run EQWatcher and Ever-Bot (a really old EQ text-to-speech program and map program) so there's a map alongside MySEQ on the right desktop.

Does anyone else do this? run MySEQ and EQ on the same computer?

Squiffy
10-06-2003, 06:36 PM
Yeah, I do that, too. Used to have 2 PCs in my room, but my new room's too tiny to do so.

In any case, I've noticed the current release of MySEQ lags the heck out of my PC, mostly zone times. Normally takes me ~30 seconds to zone. Yesterday it took me 3 and a half minutes to zone from PoK to Twilight Sea (gated)

Does Slarti's release reduce this lag?

Also, I've noticed that the mob list refreshes twice every time you zone. Initially, it repopulates the mob list/location for your old zone, then it says "Oops, he's in this new zone," pops up the new map and repopulates the mob list again. A bit inefficient. Thought about poking my nose at the source but I'm busy as all hell lately on a training course.

Gonna download Slarti's and test it out I think. Sounds like some nice changes.

Edit:
Downloaded it, put it in its own folder in the wseq directory, copied the magiclibrary.dll, and modified the options to fit my IP address. Ran it only to get the following error...

"Could not connect to server: The type initializer for "System.Net.Dns" threw an exception.

Any ideas? :confused:

TempLoginName
10-06-2003, 08:07 PM
Does Slarti's release reduce this lag?

Well, it's not lag you're experiencing, it's slowdown, but I know you knew what you meant. Everytime MySEQ refreshes it redraws the entire picture, which takes a lot of thinking. In the options page you need to make it refresh less often. I use 3000 (instead of 250) for this, so I get 2 refreshes per tick. This causes zero performance loss for me; I don't even get a stutter during the redraw (unless I reload the zone NPCs with F2, that takes a good quarter to half of a second or so depending on how big the mob list is).


Ran it only to get the following error...

Works perfectly for me, so I can't help with that. =(
I just copied the files straight into my MySEQ folder overwriting whatever it found.

Old No Name

Squiffy
10-06-2003, 08:40 PM
Hmm maybe it's missing some MySEQ files then. Will try making a dupe copy of MySEQ and overwriting Slarti's release onto it (don't wanna mess up the original MySEQ in case it still doesn't work)

And it's not slowdown while I'm playing, is the thing. Only zonetimes are affected. Frameloss is negligible. I think it's just that MySEQ is hoggin memory, preventing EQ from loading zones as fast as normal, since EQ is chugging away at the zonefile, and MySEQ is chugging away at drawing the maps and mobs twice during the zone process.

TempLoginName
10-06-2003, 09:03 PM
Frameloss is negligible.

It might not be MySEQ hogging memory necessarily; I didn't find it's CPU usage increased significantly while zoning or anything. Lag does have a huge impact on zoning, maybe it's causing serious network congestion? I really don't know; don't have that problem. =/

Anyway, before slarti's MySEQ I had to click "Stop" on MySEQ before zoning or MySEQ would crash. With his I leave it up while zoning and it doesn't hurt my zone time, I just have to hit F2 after the zone is fully loaded so mob alerts will correctly be used. I have no idea if his will work better for you while zoning, for me it crashed before, not simply hurt my load time so it's a huge improvement.

Old No Name

slartibartfast
10-07-2003, 01:40 AM
Heh horse bug was easy to fix thanx to those guru's at macroquest.

just need 1 more level of indirection.

Charinfo ptr -> charinfo struct.
Charinfo.SpawnInfo ptr - > Spawninfo struct

i made a quick + nasty web site - looks crap, but oh well, the client + server are linked in the My Favorite web sites.

- I think I fixed the 3 bugs listed above (hopefully)

Horse Bug fix requires new server. + 2 new values in the ini file:
[Memory Offsets]
CharInfo=00704040

[CharInfo Offsets]
SpawnInfo=0x0d7c

- I modified the string to int function in the server so that it can now accept hex or decimal values in the ini file (I hate having to convert back and forth). Any numbers that start with a 0 are assumed to be in hex.

My Crap Website (http://www.angelfire.com/rpg2/slartibartfast)

slartibartfast
10-07-2003, 04:25 AM
Hmm i like TempLoginName's idea for the configurable prefixes, ill add that in when i get time. I dont like the way that names with # at front sort above the alerts at the moment :(

slartibartfast
10-07-2003, 04:28 AM
Squiffy - the only thing i can think of, off the top of my head is that you dont have version 1.1 of the .net framework installed get it here (http://www.microsoft.com/downloads/details.aspx?displaylang=en&familyid=262d25e3-f589-4842-8157-034d1e7cf3a3)

TempLoginName
10-07-2003, 09:32 AM
I dont like the way that names with # at front sort above the alerts at the moment

This is EXACTLY why I want to be able to change it. =D

Thanks for the update.

Old No Name

jag111
10-08-2003, 02:40 PM
I made a couple quick modifications of my own to this version primarily to move the Races, Classes, and Bodytypes arrays out of the code and into text files that are read at startup. This way, people won't have to recompile if those lists change or people fill in the Unknown gaps.

The following two methods were added:



private string[] GetStrArrayFromTextFile(string filePath)
{
FileStream fs = new FileStream(filePath, FileMode.Open, FileAccess.Read, FileShare.Read);
StreamReader sr = new StreamReader(fs);
ArrayList al = new ArrayList();
string line;
do
{
line = sr.ReadLine();
if (line != null)
{
line = line.Trim();
if (line != "" && line.Substring(0,1) != "#")
al.Add(line);
}
} while (line != null);
sr.Close();
fs.Close();
string[] retArray = (string[])al.ToArray(Type.GetType("System.String"));
return retArray;
}

private string ArrayIndextoStr(string[] source, int index)
{
if (index < source.GetLowerBound(0) || index > source.GetUpperBound(0))
return (String.Format("{0}: OutOfRange", index));
else
return source[index];
}


The InitLookups() method is then changed to:



string appDir = AppDomain.CurrentDomain.BaseDirectory;
Classes = GetStrArrayFromTextFile(appDir + @"cfg\Classes.txt");
Races = GetStrArrayFromTextFile(appDir + @"cfg\Races.txt");
Bodytypes = GetStrArrayFromTextFile(appDir + @"cfg\BodyTypes.txt");


And the classNumToString, raceNumtoString, and typeToString methods were changed to:



public string classNumToString(int num) {
return ArrayIndextoStr(Classes, num);
}
public string raceNumtoString(uint num) {
return ArrayIndextoStr(Races, (int)num);
}
public string typeToString(byte num) {
return ArrayIndextoStr(Bodytypes, (int)num);
}


For the lazy, I've also zipped up the text files that I made from what used to be hard coded. They are here:

http://www.dvolve.net/eq/myseq/cfg.zip

jag111
10-08-2003, 03:14 PM
I've also been considering doing some cleanup of the code primarily in Form1.cs and elsewhere if I get the urge. It's mostly for organizational and readability purposes. My fear is that it won't ever get incorporated since we aren't really using CVS and when future updates are released, I'll have to re-do my cleanup.

Is it worth it?

TempLoginName
10-08-2003, 05:19 PM
I'd say wait for slartibartfast's next release, then add your code then post is asap. that way he should use your stuff. He isn't MySEQ's original author but his client kicks the suck out of the basic one.

Old No Name

P.S. - I like your coding for moving the bodytype etc. info out of the exe. I think it's a really smart move and want more info to be configurable without recompiling.

slartibartfast
10-08-2003, 06:43 PM
I added the code to load the lookups from file.

I also implemented TempLoginName's Alert changes.

for each alert type can now:
specify a prefix
specify a wave file
or disable the beep

(Personally i only want beeps for Rare mobs)

I really like how ShowEQ draws its maps, so I have started to modify the code to mimic it, I hope to add the following.

- Automatically resizes so whole map fits in window, when 100% selected.
- Smart follow of player. IE stop scrolling the map when we reach the edge.
- Add Grid Lines.
- Add code so that lines with colours that are not visible will be changed so they are visible. (Its anoying that the Map + Loy maps are designed for different colour backgrounds)

Squiffy
10-08-2003, 06:43 PM
I think I had 1.0 installed originally, not sure which release is packaged with my release of Vis Studio. Downloaded 1.1 off MS.com and installed, in any case. Didn't prompt for a reboot, but did it anyway to be safe. Same error :(

DNS in this error instance = Domain Name Server?

I run MySEQServer and Slarti's SEQ on the same local machine. The setup works fine for normal SEQ. /sigh

jag111
10-09-2003, 02:02 AM
Assuming I have time to do it, I'm also planning on fleshing out the filtering options on both the map view and list view.

Ideally I want the toggles that are already available for the map view like Show/Hide NPCs, Players, Corpses, InvisStuff....to also be available for the list view.

Then I was planning on adding more options to both like filtering Mounts, Pets, Con Ranges, etc.

Initially, I was planning on creating a new top level "View" menu that would hold all the toggle options like so:



View
- List
- NPCs (checked/unchecked)
- Players (checked/unchecked)
- Corpses (checked/unchecked)
- Invis Mobs (checked/unchecked)
- Map
- NPCs (checked/unchecked)
- Players (checked/unchecked)
- Corpses (checked/unchecked)
- Invis Mobs (checked/unchecked)
- All
- NPCs (checked/unchecked)
- Players (checked/unchecked)
- Corpses (checked/unchecked)
- Invis Mobs (checked/unchecked)


Where the All sub menu would just be an abstraction to set the toggle for both Map and List views at the same time.

The other pet peeve that I was planning on fixing was how spawns that have been hidden on the map view still generate tool tips when you mouse over them.

htw
10-09-2003, 04:48 AM
squiffy, what IP do you have in your prefs.xml?

Is it formatted correctly? Did you try removing your xml files, and letting them be recreated (and re-entering your Options)??

htw


Edit: LOL, called him squiggy....

JustAnotherUser
10-10-2003, 07:03 AM
Is it meant to draw the MobTrail Ellipses two times at Line 1118 in MapCon.cs? Reduceing it to one painting would probably free some ressources, though not much.


if (Settings.Instance.RangeCircle > 0)
{
DrawEllipse(...);
}

if (Settings.Instance.ShowMobTrails) {
foreach (MobTrailPoint mtp in mobtrails)
{
FillEllipse(whiteBrush, CalcScreenCoordX(-mtp.y)-2, CalcScreenCoordY(-mtp.x)-2, 2,2);
}
}


if (Settings.Instance.ShowMobTrails) {
foreach (MobTrailPoint mtp in mobtrails) {
FillEllipse(whiteBrush, CalcScreenCoordX(-mtp.y)-2, CalcScreenCoordY(-mtp.x)-2, 2,2);
}
}

Squiffy
10-10-2003, 02:04 PM
IP is 192.168.1.101 (my local net addy via a router, works with SEQ)
Port is 5555

I tried deleting both files and redoing options. Same error :confused:

GD_EQ
10-11-2003, 01:34 PM
Are you updating the files on your website to coincide with these changes?

slartibartfast
10-11-2003, 02:58 PM
I'll make a new version when i have finished the map changes - hopefully by the end of this weekend.

Midnight
10-13-2003, 07:50 AM
it would help us mseq users know when new releases come out if you kept a log of 'version changes' and a date of when the newest version was released (on your website). its difficult when 3-4 people post links to updates in one thread.

reaver
10-13-2003, 08:32 AM
Even a simple "Last updated" before we download those files from slarti's web site that would help.

Or adding the date to the end of the file name.zip would let us know if a newer version is out.

Thanks for all your work on this Windows project :)

-Reaver

sauron
10-13-2003, 02:04 PM
I just installed slartibartfast's version and noticed one bug.

It appears that the "Don't draw players with Con colors" does NOT work anymore. It used to draw players as a purple triangle when this checkbox was selected.

slartibartfast
10-13-2003, 03:40 PM
As stated in the notes on the first page, my version is based on netonims version.

He changed players to be drawn as yellow squares when "Don't draw players with Con colors" was checked.

I could make the colour configurable, but this would not be high on my priority list as i like the way that players with con colours are now drawn.

sauron
10-13-2003, 07:32 PM
But I was using Netonim's version (at least I thought I was) -- the verison with filters (Hunt, etc).

Regardless, I've gotten used to the boxes around the players now, and I like it! Was so used to con colors always meaning mobs...

Great work on the program Slar!