Posted: 15th Aug 2011 21:03
Is there another to write in a file?


WriteLine() and ReadLine() will output and read in plain text with new line characters, WriteString() is only meant to be read back by ReadString().
Posted: 15th Aug 2011 21:41
WriteString is also available to be used along with something like WriteInteger. A high score file for example might store the top 10 scores like this.

+ Code Snippet
for x = 1 to 10
   WriteString(fileID, Scores[x].name)
   WriteInteger(fileID, Scores[x].score)
next x
Posted: 16th Aug 2011 2:43
Well I made a simple sprite animation program and I don't know how to put it up for download for PC (publish for PC).
Any ideas?


Cheers.
Posted: 16th Aug 2011 4:16
It's mentioned in the documentation under Publishing.

Basically, in your project folder should be an EXE that has your project's name.

You need that, and you need everything in the Media folder that's in your app project folder, except for the "SourceCode.byc" file. That's your plain text source code, so you might not want to distribute that.

Zip the exe and the media folder up and you can post it for use by anyone running Windows.
Posted: 17th Aug 2011 21:47
Thanks KISTech, but it won't work without the .byc file.


Cheers.
Posted: 17th Aug 2011 22:59
Right, there's one in there after you compile called (yourappname).byc. That's the one you distribute. You don't want to leave the other one in there. That contains an interim step between your BASIC code, and the compiled bytecode file. It's not exactly like distributing your source code, but it's close.
Posted: 18th Aug 2011 2:02
Can you tell me if this is right. [attached]


Cheers.
Posted: 19th Aug 2011 2:52
You don't need the ErrorReport.txt in there, but perfect
Posted: 19th Aug 2011 2:53
Thank you Lee.


Cheers.
Posted: 20th Aug 2011 1:20
When setting a glogal dim, does it need the brackets for something like:

speed = 5

Or does it have to be:

speed [] = 5


Cheers.
Posted: 20th Aug 2011 1:38
Brackets are for arrays only.

It depends on what you want to do:

Global (could be used everywhere in your program) declaration of one value:
Global speed as Integer

Declaration of an array:
Dim speed[10]
-> Here you can save up to 10 (in this example) values
speed[1] = 5
speed[2] = 10

and so on ...
Posted: 20th Aug 2011 1:54
Here is an example of what I did:

+ Code Snippet
Global Dim speed [] as Integer

speed = 5



Cheers.
Posted: 20th Aug 2011 14:27
You don't need to 'global dim' variables.

Either global for variables or dim for arrays.