Help - Search - Members - Calendar
Full Version: Writing to File
RPG RPG Revolution Forums > Game Engines > RPG Maker VX Ace Discussion
TheScholar
See the following snippet:

@file = File.open("doc.txt", "w")
@file.write("Test One ")
@file.write("Test Two")

In RPG Maker VX this would normally write 'Test One Test Two' in doc.txt, but in RPG Maker VX-Ace it just leave the txt file empty... Anyone know a solution for this?
Kread-EX
You just forgot to close the I/O stream. Either use @file.close or a block.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2013 Invision Power Services, Inc.