Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 03-28-2012, 12:34 AM
Emera Emera is offline
Delterian Hybrid
Emera's Avatar
Join Date: Mar 2011
Location: Newcastle Upon-Tyne
Posts: 1,704
Emera is a jewel in the roughEmera is a jewel in the rough
Tile Editor Help

I've set myself the task of scripting a tile editor. Firstly though, I thought I'd take a look at some other tile editors and base my first attempt on what I can gather from them. I took a look at oo_jazz_oo's editor and coded my own from what I saw in his.

Basically, the editor works when it comes to laying tiles and such. That part I found easy. I'm quite embarrassed to say that the part I'm finding the most difficult to perfect is drawing the selecting border correctly and setting the selected tiles by dragging and such. There's a lot of math going on, and that isn't my strong point.

Here's a list of current buys I currently have.
  • Selecting tiles from the tileset image isn't working 100& correctly. It sometimes flicks back and doesn't position itself correctly.
  • After selecting tiles, the selecting border doesn't always go away and doesn't select the tiles correctly. This usually happens when drawing sideways-right rectangles.
  • When scrolling to select tiles on the other side of the panel, the GUI control detects the onMouseDown event and begins to select tiles while I'm using the scroll bars.

And here's a list of what I still need to add.
  • Selecting tiles from the level. It's only currently possible to select tiles from the tile editor, which is quite annoying.
  • Showing the player's current selection while the mouse is outside the drawing panel control.
  • Flood filling.
I'd like to say thank you to Dusty for his ImageToTile() function, and also oo_jaz_oo for his editor, so I could study it.
If anybody is able to help me out fixing these bugs, I'd be grateful!

Level Editor Code
Attached Thumbnails
Click image for larger version

Name:	leveleditor.PNG
Views:	168
Size:	138.3 KB
ID:	54444  
__________________

Last edited by Emera; 03-28-2012 at 12:48 AM..
Reply With Quote
  #2  
Old 03-28-2012, 04:27 AM
Angel_Light Angel_Light is offline
Varia Developer
Angel_Light's Avatar
Join Date: Nov 2005
Location: Knoxville, TN
Posts: 1,684
Angel_Light is on a distinguished road
Send a message via AIM to Angel_Light Send a message via MSN to Angel_Light
probably could take a look at one I made awhile ago, it can fix all the issues you have stated.

http://forums.graalonline.com/forums...hp?t=134262983
__________________
Deep into the Darkness peering...
Reply With Quote
  #3  
Old 03-28-2012, 04:01 PM
Emera Emera is offline
Delterian Hybrid
Emera's Avatar
Join Date: Mar 2011
Location: Newcastle Upon-Tyne
Posts: 1,704
Emera is a jewel in the roughEmera is a jewel in the rough
Quote:
Originally Posted by Angel_Light View Post
probably could take a look at one I made awhile ago, it can fix all the issues you have stated.

http://forums.graalonline.com/forums...hp?t=134262983
I'll check it out. Thanks.
__________________
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 09:01 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.