Results 1 to 4 of 4

Thread: How to put graphics in array?

  1. #1

    Thread Starter
    New Member
    Join Date
    Feb 2002
    Posts
    5

    How to put graphics in array?

    How do you put graphics in array?
    and then how do you make it show on the form
    sorry~
    i'm a total idiot when it comes to Vb

  2. #2
    Hyperactive Member
    Join Date
    Apr 2002
    Location
    uk
    Posts
    327
    Well, you can do this several ways. You can either place the graphics within a control array of pictureboxes or imageboxes, or you could store an array of StdPicture objects in memory.

    The solutions depends on what you're trying to do I suppose...

  3. #3

    Thread Starter
    New Member
    Join Date
    Feb 2002
    Posts
    5
    thanks fo the help, Chief
    i'm trying to make a RPG like game
    The array of pictures are for the map which the characters will be moving on

    i think i'm suppose to use a tile engine of some sort but i don't know how

    so how exactly would you put the thing in code?

  4. #4
    Hyperactive Member
    Join Date
    Apr 2002
    Location
    uk
    Posts
    327
    Well, if you're making a tile engine.... I'd do it like this:

    You don't need to store stuff in an array. Construct one large image of all your smaller image tiles in a grid. Leave no spacing between them, but they must all be the same size.
    Then, place that in a picturebox on your form.

    You can now use the BitBlt API call to copy each tile out of the box and draw it onto your main game picturebox. Look ok www.allapi.net for more info on the API.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width