Page 4 of 5

Re: Puzzle of Mystralia

Posted: Tue Aug 06, 2024 12:40 am
by SPH
Yes, one mouse now ! :!: :idea:

Re: Puzzle of Mystralia

Posted: Tue Aug 06, 2024 1:22 pm
by moulder61
I borrowed some of the code from an example by Shardik. (Thanks Shardik!)
Original post : https://www.purebasic.fr/english/viewtopic.php?t=71173

The part I used is added near the start of the code. I don't pretend to understand it but it works for Linux. :)

Code: Select all

#GDK_BLANK_CURSOR = -2

ImportC ""
  gtk_widget_get_window(*Widget.GtkWidget)
EndImport
Cursor = gdk_cursor_new_(#GDK_BLANK_CURSOR)

gdk_window_set_cursor_(gtk_widget_get_window(WindowID(win)), Cursor)
Moulder.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 12:59 pm
by SPH
v1.2c - SPH (2024)
I reworked the code to fix an artifact (September 2024).
Double mouse eliminated
Linux+ compatible
No APIs
PB Code provided
---
(look at post 1)

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 1:26 pm
by moulder61
@SPH

Sorry, it's not working for me on Linux. :cry:

My conversion, however, works perfectly. :P

Moulder.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 1:29 pm
by SPH
moulder61 wrote: Fri Sep 13, 2024 1:26 pm @SPH

Sorry, it's not working for me on Linux. :cry:

My conversion, however, works perfectly. :P

Moulder.
What are the different instructions?

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 1:37 pm
by moulder61
What are the different instructions?
Plenty! :lol:

It was a while ago that I did it, but mainly mouse button checks needed changing and the double cursor issue.

The modified source file is in my PB stuff folder. Link in the signature.

Moulder.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 1:39 pm
by moulder61
It might not work with Windows now I've edited it? But you already did that yourself, so this is for me and the 4 other Linux users to be able to enjoy your game! 8)

Moulder.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 1:47 pm
by SPH
Did you fix the graphic bug of the menu when you move the mouse around the image (when you have a resolution >1920/1080)?
If yes, then it's ok.
Personally, I made the photo of the dog and the aquarium darker. And I put "v1.2c SPH(2024)" at the bottom left.
I fixed the "Level Builder.PB" file that was buggy with PB 6.11+

That's it...

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 1:56 pm
by moulder61
Did you fix the graphic bug of the menu when you move the mouse around the image (when you have a resolution >1920/1080)?
Nope. I didn't know there was a bug and I have 1920x1080 monitors.
Personally, I made the photo of the dog and the aquarium darker. And I put "v1.2c SPH(2024)" at the bottom left.
I also made the dog, and the fox, images slightly darker. The aquarium one was a bit too colourful for me, so I substituted it for a different image.
I fixed the "Level Builder.PB" file that was buggy with PB 6.11+
I was trying to edit the level builder to work with Linux too, but never finished it. Yet!

Moulder.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 2:02 pm
by SPH
Don't hesitate to post the Linux compatible PB code here. It will please other Linux users.
Thanks for everything

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 2:11 pm
by moulder61
@SPH

I'm sure I already did in a previous post! But anyway, if anyone wants a version of your code that I modified to work in Linux, see my signature below for the link.

Just drop the file "Puzzle_1_2bLinuxVersion.pb" into the same folder as the original and it should work? :wink:

I'm up to level 55 so far. :shock:

Moulder.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 2:21 pm
by SPH
moulder61 wrote: Fri Sep 13, 2024 2:11 pm I'm up to level 55 so far. :shock:

Moulder.
I see you're having fun. Personally, I'm at level 24 (even though I'm the author)

GG

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 2:27 pm
by moulder61
I got stuck around the 20's for a bit, then made progress to the 30's and got stuck there too!

Eventually clawed my way to level 55. :lol:

It's a very nice game. Thanks.

Moulder.

Image

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 4:47 pm
by SPH
moulder61 wrote: Fri Sep 13, 2024 2:11 pm Just drop the file "Puzzle_1_2bLinuxVersion.pb" into the same folder as the original and it should work? :wink:
Error line 31 (on W10x64) :

Code: Select all

gtk_widget_get_window(*Widget.GtkWidget)
It was obvious.
I don't know anything about Linux but there may be a programming style that would be compatible.
Anyway, an error was expected.

Re: Puzzle of Mystralia

Posted: Fri Sep 13, 2024 5:18 pm
by moulder61
@SPH

I did say it might not work in Windows now I've edited it. :P

I had to edit it to get it to work in Linux. I'm not a good programmer, but I like to engineer stuff to work, so that's what I did!

Windows users have your original version already, they don't need mine.

I'm just trying to help the Linux community. 8)

Moulder.