My kingdom for a tutorial!!!

Blitz3D Forums/Blitz3D Beginners Area/My kingdom for a tutorial!!!

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Not entirely sure why you're using Data statements to create your characters when you could load a bitmap to do the job easier...
Global invader = LoadImage("alien.bmp")
Global hero = LoadImage("spaceship.bmp")
A little tip would be to use types (linked lists) for your alien spaceships. Types tend to confuse those new to the language, but they're a simple concept really. Think of it as a set of items. You know where the top one is, but you dont know how many are in the set. You can pull them out one by one to count them, but there is no limit to the number that may be in there. A more practical example would be this:
Type aliens
	Field x, y	; Coordinates of alien
	Field score	; Points scored for killing
End Type

Restore alien_positions
For x = 1 To alien_count
	alien.aliens = New aliens
	Read alien\x
	Read alien\y
	Read alien\score
Next

For a.aliens = Each aliens
	KillAlien( a )
Next

Function KillAlien( a.aliens )
	Delete a
End Function
All this code does is use data statements to built a 'database' of aliens and then loops through and wipes them out. There are more in-depth tutorials on types available, but thats pretty much the basics. There used to be a space invaders tutorial on my website - I'll see if I can dig it out sometime.