[CF-Devel] CF SDL client 0.1

Michael Toennies michael.toennies at nord-com.net
Wed Jun 27 00:56:18 CDT 2001


Hi

Here is the first release of the iso SDL client 0.1 .

     
     http://mids.student.utwente.nl/~michtoen/sdl_client/cfclientsdl.zip
     
     

and the data to setup a iso server

     
     http://mids.student.utwente.nl/~michtoen/sdl_client/isoserverdata.zip
     
     

To setup a iso server:
1.) just setup a NORMAL cvs server.
2.) copy all data in the isoserverdata.zip over the same named stuff in
share folder
3.) done. You don't need to change server code or special compiling

Note, that there is still a crossfire.xbm/crossfire.xpm, but with png files
inside.
So, don't login to this modified server with xbm/xpm client... Or your
client has
some bad seconds.

I had done the win32 implementation, the linux/max/BeOS one should
do someone else who has access to this OS.

I use native SDL:

- SDL 1.2 lib
- SDL image lib
- SDL mixer lib

I included them for win32 in sdl_win32 folder.
You has to download for a different OS the libs.

At the moment, the client can connect to a server, input with name/paswd,
going around with
num pad keys, apply with SPACE, and with the 'v' key you can fire a sound
for sound lib testing.

Input is odd yet - no cursor and perhaps not the right keyboard layout.
You can close the client by hit ESC.
When it don't work, try to hit RETURN first.

If you login, the map will shown and a not finished text windows.
The client shows iso map yet.

For every OS, there is one native module. win32.c/win32.h for win9x,
linux.c/linux.h for linux.
There is the low level socket stuff in and some other functions.

For linux, making a native version should be easy.

I use a very basic socket implementation, this should be usable for all
other OS.

The client is REAL fast.
Frames per second for my P500 with Voodoo 2000:

mode                                         fps
------------------------------------------------------
800x600 16bpp fullscreen                     90-100
800x600 16bpp windowed on 16bpp              50-55
800x600 16bpp windowed on 32bpp              50-55
800x600 32bpp windowed on 32bpp              50-30
800x600 32bpp fullscreen                     80-90 (when i remember right)

Don't try mixed modes windowed, this will destroy performance.
Also, a bad setup for he client (loading and storing bitmap data in the
false
mode) will destroy performance on a high level.

I had about 20 false stored map tiles one time, and my performance dropped
down
to 6 fps !

Ok, i need now one who does the linux convert. Should be a small work.

I have many sounds/pictures i can use from dx client, so we don't need a
widget lib.
I tested the useful libs, and most are not useful for us, to slow or simply
to powerful.
2 Libs adding full window system power to SDL, thats like you use gnome or
kde yet.
And we use only 2-3% of all there functions, so its a big big overhead.

Another problem are fonts.

I do a flirt with true type fonts, but we need 2 other libs to include them.
They are slow.
The libs don't work 100% on mac and BeOS. The fonts are 99% copyright by
others. And so on.
Perhaps one can write her something native... As libs, they are overpowered
for the few
text parts we have.

The font routine i implement will be very powerful.
Because the routine can change the attached palette for every blitted
character, we can
now include text like

msg
@match *
Hi, welcome in &Scorn
@match scorn
....
endmsg

The text will be normal color, the trigger word Scorn will shown in a
special color.
The '&' will trigger this. The '&' will then not shown, of course.
I don't include it yet, but its easy to do. 10 minutes work.

Ok, i had included so many useful interfaces like possible, this is only a 3
day work. :)

Oh yes: no key repeat yes nor real game timing. So don't wonder.


Michael


    
    


More information about the crossfire mailing list