Daimonin MMORPG Logo
Daimonin voting system

Recent Posts

[Scripts] Attack Register by smacky
April 16, 2014, 08:55:55 pm
[Dev Server] MOVED: Rewritten pick up/drop code by smacky
April 15, 2014, 03:14:20 pm
[Community chat] Clobber's Garden by Shroud
April 14, 2014, 07:32:21 pm
[Community chat] Last one to post wins! by Shroud
April 13, 2014, 08:13:28 pm
[Bug discussion] v0.10.6 Bugs by smacky
April 13, 2014, 08:05:27 pm
[Daimonin project] v0.10.7 development by smacky
April 12, 2014, 09:49:49 pm
[Arches] Joes archs by Shroud
April 07, 2014, 05:19:31 pm
[Bug discussion] Lost Skills/Levels by smacky
April 04, 2014, 04:04:54 pm

Daimonin Forums

 
Pages: [1] 2   Go Down
  Print  
Author Topic: Development client: map scaling  (Read 24274 times)
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« on: February 27, 2012, 01:40:59 pm »

Please try this revision. I've put a new exŧension library in the source which allows all sorts of nice graphical things. This was what I was aiming for earlier last year when I started working on the transparent widgets (vanilla SDL can't do that) but what with one thing and another I never got round to it. I know this compiles flawlessly on Linux and wine+CB but please test on Windows.

ATM we only use the new library (SPriG) for map zooming (or scaling is a better word). In fact this has been totally rewritten. The new system, for me, is significantly faster, especially at large screen sizes, than 0.10.5 with zoom + smoothing (we now automatically do smoothing [anti aliasing] because for some reason it is faster with than without).

It is of course a WIP and ATM you have little flexibility. So the map is always zoomed according to screen size and positioned basically horizontally centered and vertlcally below center. Things will improve in this regard (I have some old code, which was built over the old zoom system so tended to be slow, that allowed much more flexible scaling and resizing).

I'm not 100% sure I've got the calcs perfect for map drawing yet so things IMO look just a bit off at bigger scales.
zrubavel
Lesser Moroch Avatar
*
*
*
*
*
*
*



Posts: 737
Karma: +40/-10


View Profile
« Reply #1 on: February 27, 2012, 02:52:22 pm »

Here's a zipped windows versions of this client  (without a new readme .txt file)
zrubavel
Lesser Moroch Avatar
*
*
*
*
*
*
*



Posts: 737
Karma: +40/-10


View Profile
« Reply #2 on: February 27, 2012, 03:02:34 pm »

One thing I noticed is that with this new client the numbers that float from you when you are hit are the same color as the numbers that float from a mob when its hit-orange. Before (and I went to my 10.5 client to check) they used to be red and orange respectively. This is not a huge issue of course...
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #3 on: February 27, 2012, 04:30:18 pm »

Thanks Zrub. I'm not going to make that an official download yet because this is too developmentish even for a development client! In fact I have a suspicion it is inherently flawed. I think the tile calcs have to be too precise to scale up properly this way, which is why things look increasingly odd at higher res's (at 1920x1080 everything is shown a tile south and a tile east from where it actually is). A biit depressing, but salvageable I think

The colour problem is an easy fix though.
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #4 on: February 27, 2012, 05:37:19 pm »

Bah! Indeed that's the problem. I can emulate the old behaviour but if anything it is even slower (unsurprisingly as library code often is -- a nice simple API at the expense of speed). I shall have to think on this one. Perhaps if I scale only in exact multiples of tile size...

EDIT: Huzzah! It is indeed, at least partially, down to a stupid miscalculation on my part. I probably won't have time to fix it tonight though.
zrubavel
Lesser Moroch Avatar
*
*
*
*
*
*
*



Posts: 737
Karma: +40/-10


View Profile
« Reply #5 on: February 27, 2012, 08:02:31 pm »

I understand its not ready for a public download, I put it there so others with windows would try it out...I play on a laptop so I figured I was not very suited to trying this out...Although it is useful to know that (color issues aside) it seems to look fine on a small laptop screen.
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #6 on: February 27, 2012, 11:48:02 pm »

Indeed. But now I've fixed it!  :laugh: :laugh: I'll commit tomorrow and we can do an official dl.
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #7 on: February 28, 2012, 11:08:15 pm »

r6829 is the one. Now scaling is independent of screen size. You can scale map width and height to different values, both from 5% to 1000%. Currently, the map is simply centered (approximately) in the screen.

EDIT: Somehow I disabled anti aliasing at some point and right now I can't get it to work properly.
zrubavel
Lesser Moroch Avatar
*
*
*
*
*
*
*



Posts: 737
Karma: +40/-10


View Profile
« Reply #8 on: March 01, 2012, 02:46:14 pm »

Here's a link to a zipped windows version of r6386.
zrubavel
Lesser Moroch Avatar
*
*
*
*
*
*
*



Posts: 737
Karma: +40/-10


View Profile
« Reply #9 on: March 01, 2012, 03:35:13 pm »

So a couple of issues:
A.The colors of damage numbers are now fixed, but both the damage done by a char and the damage to done to him fly out of the char's sprite and not the mob (i.e. if I hit a mob for 353 hp damage an orange 353 number flies out of my body).
B. Sometimes (I think because of "fog of war")  fire storm flames stay drawn in a room long after the fire...This could have been an older issue with fog of war, but I just recently switched back to using mage so I don't know.
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #10 on: March 01, 2012, 03:46:07 pm »

A. Dammit! This is all down to me trying to be clever by merging two similar bits of code together without remembering that similar != same. Will fix.

B. I thought there might be a problem here. I'm either not keeping track properly of which image I'm recolouring for the various effects or not redrawing the map when I should be. Or both. Will fix.

Thanks for the client package. I'll do what needs to be done later on.
_people_
Warlord of Moroch Army
*
*
*
*
*
*
*



Posts: 1511
Karma: +53/-4


View Profile
« Reply #11 on: March 03, 2012, 04:04:26 am »

I think this feature is working a bit oddly. If you look closely at the edges of the map,  each tile is misaligned by a pixel or two, giving the map a rough-edged appearance.

Also, it's rendering masks oddly. This is particularly noticeable on the islands north of GH, where all of the water-earth masks are misaligned.
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #12 on: March 03, 2012, 04:23:11 am »

Does it still misalign in 800x600? Scaling is not use then so it must be my calcs.
_people_
Warlord of Moroch Army
*
*
*
*
*
*
*



Posts: 1511
Karma: +53/-4


View Profile
« Reply #13 on: March 03, 2012, 04:52:51 am »

Okay, I changed the resolution to 800x600, didn't work. So I restarted the client (logging out still causes segfault btw). When I tried to log in, it stuck at "Transfer character to map". So I logged out and tried again. This time I logged in, but a book GUI opened with a null square, two check marks, and "_person_[SA]".

Alignment issues are still occurring.
smacky
The Singular Soul of Lom Lobon Tribe
*
*
*
*
*
*
*



Posts: 8523
Karma: +272/-134


View Profile
« Reply #14 on: March 04, 2012, 12:58:50 pm »

Is it just me or has anyone else noticed that light no longer works in 6836?

Honestly trying  to coax SDL to usefully handle alpha and not destroy my X session in the process is putting me very close to postinig my own I QUIT topic every day... :grr:

Re logout segfault: Yeah I'm still waiting for some feedback from this guy. He's slow though.

http://www.daimonin.org/bugtracker/task/68
Pages: [1] 2   Go Up
 
 

Powered by SMF 2.0 RC1-1 | SMF © 2006–2008, Simple Machines LLC
Page created in 0.275 seconds with 24 queries.
Checkout