zarqon
Well-known member
[size=+1]The CanAdv Project[/size]
What is it?
CanAdv is designed as a tool for scripters, meant to be imported into their scripts. After importing, you simply call can_adv(location, prep), and the function will return true or false depending on whether or not you are able to adventure in a given location.
"Wait, what's prep?"
The second parameter is a boolean that decides whether or not to actually prepare you for going into the zone. If you call can_adv(location, true) it will equip necessary items, etc. If you call can_adv(location, false) it will only check to see that you have the necessary items, and so forth. Generally, unless you plan on actually adventuring in the given location you should use false.
How to use it:
NOTE: Special thanks to Theraze for helpfully assuming de facto responsibility for this script while I was almost entirely focused on my combat scripts.
Changelog
6.4.09 - alpha 0.1 posted. Let the collaboration begin!
6.7.09 - 0.2 changes: included resist() function, added "prep" parameter to canadv(), added four missing visit_url() calls, relocated El Vibrato, check for adventures and drunkenness.
6.17.09 - 0.3 changes: move resist() out -- script requires ZLib. Fixes for bat zones. Added equipped item and outfit checking minifuncs and integrated them. Detect St. Sneaky Pete's Day.
9.01.09 - 0.4 changes: a crapton!
9.04.09 - 0.5 changes: added Post-War Sonofa Beach.
11.17.09 - 0.6 changes: added ALL missing zones and step one of Sea zone detection. Fixed detection of completed Boss Bat's Lair.
12.30.09 - 0.62 changes: added Crimbo '09 zones as unadventurable. Use ZLib's new vprint().
10.25.10 - 0.7 changes: fixes to Boss Bat and Hippy/Frat camps (thanks psly4mne and FN Ninja!). Removed sewer, replaced old tavern with new. Added all currently missing zones -- mainly nemesis zones and Uncle P's maps.
1.28.11 - 0.71: Friar's Gate is no longer a zone. Added new Friar zones and other tweaks by Theraze.
2.16.11 - 0.72: New names for Knob zones. Limerick Dungeon checks mainstat.
2.16.11 - 0.73: Ugh. Correct URL for new Knob. Bumped nearly all verbosity settings up from 4 to 6.
Further changes are recorded below -- and on the script's SourceForge changelog.
What is it?
CanAdv is designed as a tool for scripters, meant to be imported into their scripts. After importing, you simply call can_adv(location, prep), and the function will return true or false depending on whether or not you are able to adventure in a given location.
"Wait, what's prep?"
The second parameter is a boolean that decides whether or not to actually prepare you for going into the zone. If you call can_adv(location, true) it will equip necessary items, etc. If you call can_adv(location, false) it will only check to see that you have the necessary items, and so forth. Generally, unless you plan on actually adventuring in the given location you should use false.
How to use it:
- Install it by pasting this into your CLI:
Code:svn checkout https://svn.code.sf.net/p/therazekolmafia/canadv/code/
- When writing a script, type "import <canadv.ash>" at the top of the script (without quotes). Also, ZLib will be imported along with CanAdv so you don't need to explicitly import it again.
- Enjoy using boolean can_adv( location where, boolean prep ) as an ASH function.
NOTE: Special thanks to Theraze for helpfully assuming de facto responsibility for this script while I was almost entirely focused on my combat scripts.
Changelog
6.4.09 - alpha 0.1 posted. Let the collaboration begin!
6.7.09 - 0.2 changes: included resist() function, added "prep" parameter to canadv(), added four missing visit_url() calls, relocated El Vibrato, check for adventures and drunkenness.
6.17.09 - 0.3 changes: move resist() out -- script requires ZLib. Fixes for bat zones. Added equipped item and outfit checking minifuncs and integrated them. Detect St. Sneaky Pete's Day.
9.01.09 - 0.4 changes: a crapton!
9.04.09 - 0.5 changes: added Post-War Sonofa Beach.
11.17.09 - 0.6 changes: added ALL missing zones and step one of Sea zone detection. Fixed detection of completed Boss Bat's Lair.
12.30.09 - 0.62 changes: added Crimbo '09 zones as unadventurable. Use ZLib's new vprint().
10.25.10 - 0.7 changes: fixes to Boss Bat and Hippy/Frat camps (thanks psly4mne and FN Ninja!). Removed sewer, replaced old tavern with new. Added all currently missing zones -- mainly nemesis zones and Uncle P's maps.
1.28.11 - 0.71: Friar's Gate is no longer a zone. Added new Friar zones and other tweaks by Theraze.
2.16.11 - 0.72: New names for Knob zones. Limerick Dungeon checks mainstat.
2.16.11 - 0.73: Ugh. Correct URL for new Knob. Bumped nearly all verbosity settings up from 4 to 6.
Further changes are recorded below -- and on the script's SourceForge changelog.
Last edited: