It is currently Sun Dec 17, 2017 3:31 am


Post new topic Reply to topic  [ 33 posts ]  Go to page Previous  1, 2, 3, 4  Next
Author Message
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Fri Nov 19, 2010 9:18 am 
User avatar

Joined: Tue Oct 13, 2009 12:06 am
Posts: 270
Wow, really surprising, never would have guessed those boxes to make trouble.
And I think they are really superfluous now, nothing left to draw over.
And I'd expect that if it was slowing thing down to be constantly slow.
That theses boxes make the game getting slower and slower is really surprising.
Especially for the SVN version where idle mode is working correctly now.
On my antique 900 Mhz AMD, laby eats less than 2% cpu time in main loop now...

Yes, Pure Basic can create Linux binaries. The main reason for Markus to fork a Pure Basic version from the original Blitz Basic one was to get the game running on Linux too.

But with closed source compiler, there is no way to ever get into package collection of any distro. With the elice converter we can make whole game with open source. Once we get rid of the remaining offending pictures and sounds we have a good chance to get the game in there. Additionally,we may make things like mousewheel work with elice (SDL does support it). PB does support this only for windows.


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Fri Nov 19, 2010 12:35 pm 
User avatar

Joined: Thu Nov 11, 2010 12:38 am
Posts: 161
Location: Norway
Then does it not make more sense to convert the whole game to c++ and step away from PureBasic? If the elice converter handles the most of the work, you could pretty easily convert the project to c++.

_________________
Lost Labyrinth Developer
Check out my other game: Egoboo


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Fri Nov 19, 2010 3:08 pm 
Site Admin
User avatar

Joined: Mon Oct 12, 2009 2:30 am
Posts: 232
We already considered that but programming with purebasic syntax is a lot faster than with c++. We want to concentrate on the game not on the programming language.

The issue with mingw on windows exists either way. If you would like to help you would be welcome because Bernd and I do not use windows and we could really use somebody that is good in c++ programming.

That is how far I already get:

Code:
How to compile laby with mingw on Windows
---------------------------------
1. Download tortoisesvn from tortoisesvn.tigris.org and install it
2. With tortoisesvn check out laby from its subversion directory on sourceforge:
   https://lostlaby.svn.sourceforge.net/svnroot/lostlaby
3. Install mingw from http.//www.mingw.org (Automated installer, mingw-get-inst)
   (Install into C:\MinGW and select the C++ compiler to be installed)
4. Make the gnu compiler executable from everywhere:
   In the Startmenu Rightclick on "My Computer" select System Properties.
   In the advanced tab click on "Environment Variables".
   Change the Value of "Path" and add ";C:\MinGW\bin"
   This requires a restart to work. Or you can do:
   path = %PATH%;C:\MinGW\bin
   in the Commandline to change it instantly.
5. Copy all SDL header files from lostlaby\pb\SDL4Windows_h to C:\MinGW\lib\gcc\mingw32\4.5.0\include
6. Copy all SDL lib files  from lostlaby\pb\SDL4Windows_libs to C:\MinGW\lib
7. Compile the game:
   g++ -lm -lmingw32 -lSDLmain -lSDL -lSDL_gfx -lSDL_ttf -lSDL_mixer -lSDL_image laby.cc -o laby.exe


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Fri Nov 19, 2010 3:24 pm 
Site Admin
User avatar

Joined: Mon Oct 12, 2009 2:30 am
Posts: 232
To get the c++ code you have to run elice like this:
Code:
elice -save-temps laby.pb


Maybe you install kubuntu 10.10 in a virtual machine to do that.
I have windows running in a virtualbox (to try around) and in wine (to compile laby for the release).

I just had a look what happens when I remove the box drawing and we get graphical glitches then. When you move to the left you can see that parts of the laby that is scrolled is appearing under the lifepoints.


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Fri Nov 19, 2010 11:39 pm 
User avatar

Joined: Thu Nov 11, 2010 12:38 am
Posts: 161
Location: Norway
I use visual studio to compile C and C++ code. I might consider helping you if I weren't so busy with other stuff. I am already involved in a open source roguelike called Egoboo in addition to numerous other minor projects. I have also a pretty busy life until the christmas vacations begin. But I will see if I get the time to try to compile LostLaby under c++

Also, if those SDL libraries aren't linked statically, you will need to supply the actual DLL's with each release. I usually try to link libraries statically so that the game runs without any external DLL files required. (the compiler will also remove unused stuff and even do some optimizations if it is linked statically as well)

If I get the C++ version to compile, I can use the Visual Studio debugger to exactly pinpoint any problem I might be having running lost laby.

_________________
Lost Labyrinth Developer
Check out my other game: Egoboo


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Sat Nov 20, 2010 10:17 pm 
Site Admin
User avatar

Joined: Mon Oct 12, 2009 2:30 am
Posts: 232
I have no clue how close vc++ und g++ are.
The perfect solution would be to use the code that elice produces,
maybe transformed by a small script?
I already found some things that have to be changed to make it compile:

Code:
#define random rand
#define srandom srand

#include <Winsock2.h>
//#include <netdb.h>
//#include <sys/socket.h>

mkdir(p1.c_str(), 0777); -> mkdir(p1.c_str());
has to be removes for now:
intptr_t p_opennetworkconnection

 main(){ has to look like this:
#ifdef __cplusplus
extern "C"
#endif
int main (int argc, char *argv[]) {


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Thu Nov 25, 2010 3:41 pm 
User avatar

Joined: Thu Nov 11, 2010 12:38 am
Posts: 161
Location: Norway
Hello again. I've tested the new version and I'm afraid the slowdown issue is still there.

After a small while the movement creeps up to a severe slowdown where it takes a second to move 1 tile. Ambushes also have the problem where it takes about 3 seconds for a monster to appear. In a T intersection I have to wait 9 seconds before the game can continue :(

_________________
Lost Labyrinth Developer
Check out my other game: Egoboo


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Thu Nov 25, 2010 4:24 pm 
Site Admin
User avatar

Joined: Mon Oct 12, 2009 2:30 am
Posts: 232
I just had a look at the code and I found more places where the boxes are used.
I already replaced all of them in the svn.
If you find the time please compile this version and let me know if this finally solves your problem.


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Fri Nov 26, 2010 12:12 am 
User avatar

Joined: Tue Oct 13, 2009 12:06 am
Posts: 270
I'd like to know:
1. Does this slowdown appear both windowed and fullscreen?
2. Is the game eating all cpu time still?
(might slowdown without eating all cpu if delay procedure runs amok)
(We got one user where delay does not delay anything so animations are all too fast instead, so might be something similar)
3. What happens if you open other screens after slowdown?
Is inventory,charinfo , casting etc. also creeping?
4. If cpu usage goes up, does this happen only from walking around or just over time, like when standing on starting point for some minutes.
5. Does the game keep crawling if you abort to title and start new or load game?
6. If you safe a game that is crawling , quit game and restart and load from title..
Will it start slow already then?

Also might be the case those box drawing is totally innocent if removing those boxes did not solve your problem.


Top
 OfflineProfile  
 Post subject: Re: Lost Labyrinth Windows 7
PostPosted: Thu Dec 09, 2010 3:53 pm 
User avatar

Joined: Thu Nov 11, 2010 12:38 am
Posts: 161
Location: Norway
Sorry about the late reply, I've been really busy lately. I will try those things out and report what happens.

_________________
Lost Labyrinth Developer
Check out my other game: Egoboo


Top
 OfflineProfile  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 33 posts ]  Go to page Previous  1, 2, 3, 4  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
GuildWarsAlliance Style by Daniel St. Jules of Gamexe.net
Guild Wars™ is a trademark of NCsoft Corporation. All rights reserved.