Hello,
I am attempting to code a map editor in PureBasic. Since this is the first time I am doing anything proper using the Windows GUI, I have run into some problems. Any help will be appreciated.
First of all, this is what I've managed so far:
http://web.sfc.keio.ac.jp/~t03341kg/temp/editor.pb
In this editor, the map tiles are to be selected in the Scroll Area Gadget on the right, and then plotted onto the area on the left. Since the image gadget doesn't have any input function, would using "WindowMouseX()" and "WindowMouseX()" be the only way I could do this? Since the point (0, 0) in my map area is something like (60, 4) of the window, it seems too messy to be the proper way.
Any advice on how I could handle this type of program more efficiently is greatly appreciated.
By the way, this is a screenshot of the map editor I aim to imitate. It's a RPG creating tool famous in Japan.
Thank you for you time.
-Shopro
Map Editor
-
- User
- Posts: 60
- Joined: Wed Apr 30, 2003 2:25 pm
- Location: Västerås
- Contact:
That looks nice, maybe you should do a Alt+Print Screen next time or write a command to make a screenshot
Thats what i am using for a 3D-Game that a few friends of me, and of course I am writeing.
Code: Select all
If KeyboardPushed(#PB_Key_F12)
GrabSprite(#1, 0,0, 640, 480, 0)
UseJPEGImageEncoder()
SaveSprite(#1, "C:\techtest1.jpg", #PB_ImagePlugin_JPEG)
EndIf