Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Public testimage As Image
- Public MovementGrid(23, 23) As Point 'the grid everything moves on. since everything will be 24x24 the points will be 8down and 8 to the right of each corner.
- Private Sub map_Load(sender As Object, e As EventArgs) Handles MyBase.Load
- 'Dim temp As Image
- 'temp = Image.FromFile("Art\maps\map template small.png")
- 'Me.BackgroundImage = temp
- 'Me.BackgroundImageLayout = ImageLayout.None
- testimage = Image.FromFile("Art\CharacterPlaceholder.png")
- Dim a As Integer = 260
- Dim b As Integer = 4
- For i As Integer = 0 To 23 Step 1
- For j As Integer = 0 To 23 Step 1
- MovementGrid(i, j) = New Point(a, b)
- Dim test As New PictureBox
- test.Image = testimage
- test.Size = New Size(24, 24)
- test.Location = MovementGrid(i, j)
- Me.Controls.Add(test)
- a += 32
- Next
- a = 260
- b += 32
- Next
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment