Page 1 of 1
Looking for solid examples of ${Ini[]} useage for the readme
Posted: Fri Apr 30, 2004 6:57 am
by wassup
If anyone who uses ini files alot wouldn't mind posting a few solid examples of reading single and multiple values and also creating ini files with single and multiple values, I would appreciate it greatly.
Posted: Fri Apr 30, 2004 8:44 am
by LordGiddion
fairly random selection from Genbot if you want something a bit cleaner I can do something specific for this.
Code: Select all
/varset FastMin ${Ini[${IniFile},Core,FastMin,99999]}
/if (${FastMin}==99999) {
/ini ${IniFile} Core FastMin 6
/varset FastMin 6
}
/varset Relaytells ${Ini[${IniFile},Core,Relaytells,1]}
/if (${Relaytells}==1) {
/ini ${IniFile} Core Relaytells 1
/varset Relaytells 1
}
/varset ListenGroup ${Ini[${IniFile},Core,ListenGroup,1]}
/if (${ListenGroup}==1) {
/ini ${IniFile} Core ListenGroup 1
/varset ListenGroup 1
}
/varset ListenChat ${Ini[${IniFile},Core,ListenChat,0]}
/if (${ListenChat}==0) {
/ini ${IniFile} Core ListenChat 0
/varset ListenChat 0
}
/varset ListenChan ${Ini[${IniFile},Core,ListenChan,NotFound]}
/if (${ListenChan.Equal[NotFound]}) {
/ini ${IniFile} Core ListenChan "Listen channel"
/varset ListenChan "Listen channel"
}
might wanna check
Posted: Mon May 03, 2004 4:38 pm
by Calon
There is a post under snippets section by Preocts which is really well commented that can show you how to use ini files at
http://macroquest2.com/phpBB2/viewtopic.php?t=6917