   2d Map Editor in Visual Basic?
  Basically, I'm trying to create a map editor in VB for a simple 2d rpg game that I'm about to create (in C++ btw). The maps will be divided into tiles, each which contains the location of image for the terrains, and also other some other properties. What I need is basically a program that can read, edit, and view the maps files (which I'm planning to save as text files). Currently, I'm planning to create a bunch of pictureboxes (around 100 of them), each representing a single tile in the map. The pictureboxes will display the image of the tile it represents. Also, when a picturebox is clicked, the program will display information about the corresponding tile, which can also be edited and saved. So my question is, what is a good way to create and organize all these pictureboxes? I'm planning to create an array of pictureboxes, but I'm not really sure how it can be done (I'm new to visual basic btw)...any suggestions or advice will be welcomed. thanks   
  I made a tile based game in VB a few years ago, and i had the same problem. In the end I bypassed pictureboxes altogether and used the windows GDI from brilliant tutorials at VBexplorerHope that could help you too. Also, why exactly are you making the editor in vb if you are making the game in c++   ;  When you say "VB" do you mean VB6 or VB.net?   ;Quote:Original post by programmer88I made a tile based game in VB a few years ago, and i had the same problem. In the end I bypassed pictureboxes altogether and used the windows GDI from brilliant tutorials at VBexplorerHope that could help you too. Also, why exactly are you making the editor in vb if you are making the game in c++probably because it's easier.  i plan on doing something very similar but am going to use C# for the level editor.   ;  Thanks for all the replies so far!Quote:Original post by programmer88Hope that could help you too. Also, why exactly are you making the editor in vb if you are making the game in c++I was planning to make my editor in c++ as well.. but i thought that it might be easier and faster to make it in VD, since its a relatively easy program... and since I've never programming in VD before, I thought it would be a good chance for me to learn it and get some experience from it :Pbtw, can you provide a little more detail about the method you used instead of pictureboxes?Quote:Original post by MJPWhen you say "VB" do you mean VB6 or VB.net?I think its VB.net, since I'm currently using visual basic 2008...   ;Quote:Original post by CustomDriveI think its VB.net, since I'm currently using visual basic 2008...Yeah, that's VB.net.  I was just making sure, because VB6 is the devil.  VB.net is much much nicer.;  well my method used vb6, but i dunno about vb.net (i made the switch to c++). Basically what i did was take the device context of the main form of the program and blitted each tile on in its individual place. For the input i used the forms mousedown function and calculated which tile it was on by lookin at the x,y position (in pixels) on the form where the mouse was clicked.PS I think these are the tutorials i used...but i cant remember:here;  Don't make 100 pictureboxes, look up the Graphics class which has plenty of drawing routines, and you can create one for a picturebox using PicBoxName.CreateGraphics(). It's also an event parameter for Paint events. Simple grid math can help you determine where the user clicked.   