Blitz3D Docs -> 2D - A-Z -> D -> Data
Parameters:list_of_values = a list of comma delimited values (strings must be inside quotes)
Description:Data is used to create neat, comma delimited lists of values of a constant nature that you will be reading (and probably reusing) during the execution of your game. You may store level information (number of enemies, stars, etc) there or just about anything you can think of! You can easily mix datatypes (strings, integers, floats) in your Data statements, as long as they are read properly with the Read command later. You will need to use the Restore command to point to the .Label that begins your Data statements. See the related commands for more information and more examples.
See also: Read, Restore.
Example:[bbcode]Print "Here we go!"
; Restore to the start of the Data statements
; Get the first number which is the total number of users
; Print them all!
For T = 1 To Users
Print firstname$ + " " + lastname$ + " is " + age + " years old with " + accuracy# + " accuracy!"
While Not KeyHit(1)
Data "Shane", 31, 33.3333, "Monroe"
Data "Bob", 28, 12.25, "Smith"
Data "Roger", 54, 66.66, "Rabbit"[/bbcode]
Blitz3D Manual Forum
BlitzPlus Equivalent Command
|Blitz BASIC Founders Fund|