Results 1 to 3 of 3

Thread: [VB6] Multiple data files to array (for tile games)

  1. #1

    Thread Starter
    Fanatic Member damasterjo's Avatar
    Join Date
    Nov 2005
    Location
    In front of my Comp DirectX7 EXpert
    Posts
    827

    [VB6] Multiple data files to array (for tile games)

    This example will take 10 text files full of map information and assign them into one 3 dimensional array.
    Attached Files Attached Files
    Last edited by Hack; Feb 10th, 2006 at 10:44 AM.
    Software languages known:
    Qbasic - TI-Basic - Liberty Basic - Visual Basic 6
    Software API's known:
    Directx 7 and 8
    Internet languages, in the process of learning:
    HTML - JAVASCRIPT - PHP - CSS - MYSQL - AJAX

  2. #2
    Giants World Champs!!!! Mark Gambo's Avatar
    Join Date
    Sep 2003
    Location
    Colorado
    Posts
    2,965

    Re: VB6-Multiple data files to array (for tile games)

    Why wouldn't you Dimension the variable "Maps" as a String or Integer?


    VB Code:
    1. Dim maps(1 To 10, 1 To 15, 1 To 12) As String
    Regards,

    Mark

    Please remember to rate posts! Rate any post you find helpful. Use the link to the left - "Rate this Post". Please use [highlight='vb'] your code goes in here [/highlight] tags when posting code. When a question you asked has been resolved, please go to the top of the original post and click "Thread Tools" then select "Mark Thread Resolved."


  3. #3

    Thread Starter
    Fanatic Member damasterjo's Avatar
    Join Date
    Nov 2005
    Location
    In front of my Comp DirectX7 EXpert
    Posts
    827

    Re: VB6-Multiple data files to array (for tile games)

    guess I didnt think of it, If your going to have less that 256 images and dont plan on using negative, set it as a byte! Good question though, I need to work on not leaving my variables as variants by default, it possible could slow down a game.
    Software languages known:
    Qbasic - TI-Basic - Liberty Basic - Visual Basic 6
    Software API's known:
    Directx 7 and 8
    Internet languages, in the process of learning:
    HTML - JAVASCRIPT - PHP - CSS - MYSQL - AJAX

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