Adventure Game Studio

AGS Support => Modules, Plugins & Tools => Topic started by: RickJ on Thu 27/01/2005 18:24:15

Title: MODULE: IniFile
Post by: RickJ on Thu 27/01/2005 18:24:15
AGS v2.7+ has a new feature allowing script modules to be created and used in a fashion similar to plug-ins.  So I took the liberty of making a module that provides support for reading INI configuration files, similar to the acsetup.cfg file AGS uses.  This was brought up a couple of months ago in a thread by Radiant (http://www.adventuregamestudio.co.uk/yabb/index.php?topic=17911).

Here is a link to the module.  I have included my test game for convenience.  Just unzip it to a game folder and open it with the AGS editor and do a Game->Test.  Have a look and let me know what you think.  Also please also comment on coding, documenting,  and publishing modules and in general.

Download here (http://www.gaia-spa.com/project/ags/modules/IniFile002.zip)
Mirror (http://www.americangirlscouts.org/agsresources/)

Are any other features needed or desired?  If so what?  Any bugs or incorrect operation?   Any incorrect or confusing documentation?   Current documentation is a bit redundant.  I prefer not to write about the same things in multiple places because it is nearly impossible to keep everything upto date. Any ideas about how to clean this up?
Title: Re: MODULE: IniFile
Post by: Rui 'Trovatore' Pires on Wed 02/02/2005 09:51:55
Do you feel that it is final and documented enough for general and public consumption? If so, let me know and with your blessing I'll upload it to my resource site.
Title: Re: MODULE: IniFile
Post by: Scorpiorus on Thu 03/02/2005 19:40:50
Nice work with the module! :)

I was just browsing the module script and noticed:
[line 548]: len = secptr-this.nextptr+1;
which AGS treats as "len = secptr-(this.nextptr+1);"
instead of "len = (secptr-this.nextptr)+1;"
Title: Re: MODULE: IniFile
Post by: RickJ on Thu 10/02/2005 06:25:46
Quote
I was just browsing the module script and noticed:
[line 548]: len = secptr-this.nextptr+1;
which AGS treats as "len = secptr-(this.nextptr+1);"
instead of "len = (secptr-this.nextptr)+1;"
Thanks a bunch. I'll look into it and get it fixed. 

Quote
Do you feel that it is final and documented enough for general and public consumption? If so, let me know and with your blessing I'll upload it to my resource site.
Rui, you're quite welcome to mirror it. I would say if someone has a need for it they could definitely start using it. As you can see from the original thread (http://www.adventuregamestudio.co.uk/yabb/index.php?topic=22672) most of the issues are related to modules in general. Although, Scorp has identified a few things I overlooked. I think the Get functions need to be enhanced a bit so they can be used to dump a whole section or the whole buffer (i.e. if someone wanted to load a listbox with the contents of a section for example).
Title: Re: MODULE: IniFile
Post by: SSH on Fri 09/09/2005 16:59:06
The Inifile.txt document in the Inifile zip seems to go on about copying stuff into global script, etc. I guess this comes from before AGS module support was added and needs updating...

Thanks!
Title: Re: MODULE: IniFile
Post by: tiagocorreia on Tue 27/06/2006 12:22:13
This module doesn't seems to work on the latest version of AGS 2.72.

I've disabled the enforce new string styles.

Do you think you can fix it, or it better for me to try to fix it?
Title: Re: MODULE: IniFile
Post by: Kweepa on Wed 28/06/2006 04:16:40
RickJ hasn't posted in a month or so... I think you might be on your own.