Wintermute Engine Forum

Wintermute Engine => Scripts, plugins, utilities, goodies => Topic started by: MMR on June 10, 2004, 05:54:45 PM

Title: Write / Read Text Files Plug-in
Post by: MMR on June 10, 2004, 05:54:45 PM
Well, here is a new plug-in for WME  ;D

You can download it from here: http://www.algarinejoven.com/wintermute/ejemplos/filesDLL.exe

Basically it can:
* Create text files
* Write inside them
* Read from them
* Delete text lines
* Know how many lines has a file

It's the first version, but works pretty well  ;)
I also include a example project wich uses all these functions.

I hope this could help you to develop you game  ::)

Note: The DLL file must be in the same folder wme.exe is

EDIT: Updated link
Title: Re: Write / Read Text Files Plug-in
Post by: Mnemonic on June 10, 2004, 06:48:25 PM
Great job, Manuel. It seems to be working nicely. Thanks :)
Title: Re: Write / Read Text Files Plug-in
Post by: McCoy on June 10, 2004, 06:57:35 PM
Ahaha, at last you finished it!

You're da man!

So how did you finally got rid of the annoying memory leak problem?
Title: Re: Write / Read Text Files Plug-in
Post by: Jerrot on June 11, 2004, 08:39:41 AM
Well, here is a new plug-in for WME
Title: Re: Write / Read Text Files Plug-in
Post by: gfx johnny on June 11, 2004, 09:09:42 AM
This is great, thank you for sharing it with us!
Title: Re: Write / Read Text Files Plug-in
Post by: Igorrr on June 11, 2004, 11:32:20 AM
Whoooooooooooooooooooooooo !!!!

GREAT WORK MMR!!!!
Title: Re: Write / Read Text Files Plug-in
Post by: MMR on June 11, 2004, 02:08:15 PM
Thanks to all of you!

Quote
McCoy: So how did you finally got rid of the annoying memory leak problem?

Mnemonic told me to reserve the memory for the string through WME scripting. That's why you have to write something like...

Code: [Select]
var MyString = new String(256);
And then use MyString in some functions call ;)
Title: Re: Write / Read Text Files Plug-in
Post by: Mnemonic on June 11, 2004, 02:11:20 PM
Yes, so that the string is entirely managed by WME. One thing, MMR, the cleanest solution would be to pass the length of the pre-allocated string to the plugin, so that it doesn't oveflow when reading a long line from the file.
Title: Re: Write / Read Text Files Plug-in
Post by: MMR on June 11, 2004, 02:13:43 PM
Yep, you're right.

I've done it, and the file is Updated  ;)
Title: Re: Write / Read Text Files Plug-in
Post by: Ron_Emad2 on March 19, 2010, 12:34:06 PM
Hello
Please fix this link becuse it dont work
with thanks
Title: Re: Write / Read Text Files Plug-in
Post by: Mnemonic on March 19, 2010, 12:37:20 PM
Ron_Emad2: This is a very old thread. In the meantime, WME got native support for file access. See the File object in documentation.
Title: Re: Write / Read Text Files Plug-in
Post by: Ron_Emad2 on March 19, 2010, 04:02:49 PM
Oh Forgive me
i find it in documentation
thanks
Title: Re: Write / Read Text Files Plug-in
Post by: Gambit on March 21, 2010, 02:16:17 AM
dead link
Error 404 - No Encontrado  :'(
Title: Re: Write / Read Text Files Plug-in
Post by: odnorf on March 21, 2010, 12:32:15 PM
Please, read Mnemonic's post.
Title: Re: Write / Read Text Files Plug-in
Post by: lfkk77 on December 14, 2010, 09:35:02 PM
hi,MMR.Thank you very much!
Link is bad, can provide a new Download address? Thank you very much! ???
Title: Re: Write / Read Text Files Plug-in
Post by: odnorf on December 14, 2010, 09:43:04 PM
Please, read the thread.
Title: Re: Write / Read Text Files Plug-in
Post by: MMR on December 21, 2010, 11:21:18 PM
Hi lfkk77,

This plugin is not needed as that functionality is already implemented in the current version of WME.

Cheers!