![]() |
Don't load the map twice - Printable Version +- Mirage Engine (https://mirage-engine.uk/forums) +-- Forum: Mirage Source (Nostalgia) (https://mirage-engine.uk/forums/forumdisplay.php?fid=61) +--- Forum: Archive (2006-2011) (https://mirage-engine.uk/forums/forumdisplay.php?fid=18) +---- Forum: Resources (https://mirage-engine.uk/forums/forumdisplay.php?fid=49) +---- Thread: Don't load the map twice (/showthread.php?tid=94) |
Don't load the map twice - Misunderstood - 04-06-2006 eh, its somewhat of a bugfix, but I already posted it in tutorials, so heres the link... http://www.ms.shannaracorp.com/forums/viewtopic.php?t=23 What currently happens is the entire map is loaded to get the revision to see if the client has the right version or not, if it does, it loads the map again. What I did was make it load the map, check if it has the right version, if it does, it makes savemap = to the map already loaded, so the map doesn't need to be loaded twice. - Bradyok - 05-06-2006 I would say that is a bug fix. - William - 05-06-2006 Yeah thank you Miss, its a bug fix. - Misunderstood - 06-06-2006 Dave Wrote:Can't believe no one has caught that I was pretty amazed myself ![]() I only found it cause I was moving the client to java. - William - 03-02-2007 The url do not longer work, not sure if I remember but should it be like this? Code: If GetMapRevision(x) y Then The instead of =. - Dragoons Master - 03-02-2007 Actualy is = and not . If the Revision you have on your map is the same as the one the server has, then you dont need to receive the map and just load it. - Misunderstood - 03-02-2007 No. The tutorial replaced GetMapRevision It loaded the map into tempMap after modifing loadmap (or you could have created a getMap to return a map it loads then it checks the revisions, and if equal, it sets savemap = to tempmap - Cruzn - 03-02-2007 William Wrote:The url do not longer work, not sure if I remember but should it be like this?http://key2heaven.net/ms/forums/viewtopic.php?t=23 Incase you haven't figured it out already. =) Re: Don't load the map twice - shaded - 25-05-2008 Ok I hate to bring this up again(cause of old date), but I noticed that I of course still had the bug where it ALWAYS requested a new map. Well I made these changes and it seems to work perfectly fine now. I Changed: If FileExist(MAP_PATH & "map" & x & MAP_EXT, True) Then To: If FileExist(MAP_PATH & "map" & x & MAP_EXT, False) = True Then Code: If FileExist(MAP_PATH & "map" & x & MAP_EXT, False) = True Then I tested it and had it display every time I was on a new map or an old map; had my girlfriend make a simple change and it showed I was on a new map. While walking around on the old maps it displayed I was on an old map. I noticed their was an optimizing tutorial and some other stuff. Do they make this any better? Cause the fix I made actually seemed to work perfectly fine all the time and I noticed that the maps were loading quicker. |