Inn Coupons (Free Inn Stays)
Lodge donation points purchase for free inn stays. Buy packages of 10 coupons for 30 donator points (default cost setting). Purchase from Percy Weasley at Prefect's Lounge (lodge.php). Coupons stored in availablestays preference, displayed as navigation option at inn: "Show him your coupon for X inn stays." Using coupon: consumes 1 stay from availablestays counter, sets boughtroomtoday=1, logs you out to inn location, sets restorepage=inn.php?op=strolldown (standard inn wakeup page). Identical effect to paying for inn room but FREE (no gold cost). Where donation points buy you the ability to skip paying 90 gold (or whatever inn costs) to advance the game day.
Overview
What Are Inn Coupons?:
- Lodge purchase converting donation points → free inn stays
- Packages of 10 stays per purchase
- Cost: 30 donation points (default, configurable)
- Vendor: Percy Weasley at Prefect's Lounge
- Storage: availablestays user preference (cumulative)
- Usage: At inn, show coupon instead of paying gold
Why Use Inn Coupons?:
- Save gold on daily inn stays
- Convenience (one-click sleep without gold transaction)
- Good use of excess donation points
- Accumulate stays for future use (no expiration)
Purchasing Coupons
Location:
- Prefect's Lounge (lodge.php)
- Navigation: "Inn Coupons (30 points)" (displays cost)
- Hook: lodge (adds navigation to shop section)
Purchase Process:
- 1. Click "Inn Coupons (30 points)" in Prefect's Lounge
- 2. Percy Weasley: "Ten free nights in [inn name] will cost 30 points. Will this suit you?"
- 3. Confirm: Yes or No
- 4. If Yes && sufficient points:
- Percy: "Gives you a card that reads 'Coupon: Good for ten free stays at [inn name]'"
- availablestays += 10
- donationspent += cost (30 points default)
- 5. If insufficient points:
- Percy: "I'm sorry, but you do not have the 30 points required. Please return when you do."
- No purchase
Cost Calculation:
- cost setting (default: 30 donation points)
- Checks: donation - donationspent >= cost
- Example: 50 total donation, 20 spent → 30 available (can buy 1 package)
Using Coupons
Inn Navigation:
- Hook: innrooms (adds coupon option to inn room selection)
- If availablestays == 1: "Show him your coupon for 1 inn stay"
- If availablestays == 2-10: "Show him your coupon for X inn stays" (plural)
- If availablestays > 10: "Show him your coupons for X inn stays" (coupons plural)
- Only appears if availablestays > 0
Usage Process:
- 1. At inn, click coupon navigation option
- 2. runmodule.php?module=inncoupons&op=room
- 3. Module executes:
- availablestays-- (consume 1 stay)
- loggedin → 0 (log out)
- location → inn name
- boughtroomtoday → 1 (flag: already bought room)
- restorepage → "inn.php?op=strolldown" (wakeup page)
- saveuser()
- Redirect to index.php (logout)
- 4. Result: Logged out, will wake up at inn next login
Effect:
- Identical to paying for inn room
- Advances to newday
- Wakes up at inn.php?op=strolldown
- boughtroomtoday flag prevents buying another room same day
- Difference: No gold cost (coupon consumed instead)
Coupon Accumulation
Stacking:
- availablestays pref is cumulative
- Buy multiple packages: stays add together
- Example: Buy 3 packages = 30 stays total
- No maximum limit (can accumulate hundreds)
No Expiration:
- Coupons never expire
- Persist across newdays, VE cycles, indefinitely
- Can stockpile for future use
Legacy Config Migration:
- Old system: donationconfig['innstays']
- Module checks donationconfig on purchase/use
- If innstays found: Migrates to availablestays pref, clears from config
- Ensures backward compatibility with old coupon storage
Value Analysis
Cost Comparison:
- Inn room cost: Varies by inn (default capital: ~90 gold?)
- 10 coupons: 30 donation points
- Per stay: 3 donation points
- Gold saved: 10 rooms × inn cost
- Example: 10 rooms × 90 gold = 900 gold saved
Donation Point Value:
- Donation points acquired via real-world donations (or events)
- Various lodge purchases available (name color, etc.)
- Inn coupons: Low-cost utility purchase
- Trade-off: Points for convenience + gold savings
Is It Worth It?:
- Yes, if:
- You have excess donation points
- You value convenience (one-click sleep)
- You want to save gold for other purchases
- Inn costs are high on your server
- No, if:
- You need donation points for other lodge purchases (name color, etc.)
- Gold is not scarce for you
- You prefer to keep points for future features
Integration with Inn System
Standard Inn Flow:
- Player visits inn
- Chooses room type (common, basic, deluxe, etc.)
- Pays gold based on room choice
- Logs out, advances to newday
Coupon Flow:
- Player visits inn
- Shows coupon (if availablestays > 0)
- NO gold payment
- Logs out, advances to newday
- Same result as paying for room
Hook Priority:
- innrooms hook adds coupon navigation
- Appears alongside standard room options
- Player chooses: pay gold OR use coupon
Pointsdesc Integration
Lodge Description Hook:
- Hook: pointsdesc (describes donation point purchases)
- Adds: "The cost for ten free stays at the inn is %s points"
- Displays cost setting (default: 30)
- Helps players understand pricing before purchase
Settings & Configuration
Module Settings:
- cost: 30 points (default, how many points for 10 stays)
- Can be adjusted by admins per server economy
User Preferences:
- availablestays: Integer count of remaining free stays
- Decrements by 1 each use
- Increments by 10 each purchase
- No maximum limit
Limitations
- Requires Donation Points: Need points to purchase (real-world donations or events)
- Fixed Package Size: Can only buy packages of 10 (can't buy 1-9)
- No Refunds: Once purchased, cannot convert back to points
- Same Effect as Paying: No bonus benefit, just free room (no extra HP/buffs)
- boughtroomtoday Flag: Using coupon sets flag, prevents buying another room same day
Strategy Guide
When to Buy:
- After buying other priority lodge purchases (name color if desired)
- When you have 30+ spare donation points
- If you plan to play long-term (use coupons over time)
- During donation point events (if bonus points offered)
When to Use:
- Any time you'd normally pay for inn room
- When low on gold (save gold for other purchases)
- For convenience (faster than selecting room type + paying)
Stockpiling:
- Safe to buy multiple packages (coupons never expire)
- 100+ stays = 1+ year of daily use
- Good long-term investment of donation points
Comparison to Other Lodge Purchases
Inn Coupons vs Other Options:
- Name Color: 2000 points first time, 5000 subsequent (cosmetic, permanent)
- Inn Coupons: 30 points per 10 stays (utility, consumable)
- Other Purchases: Vary by module (mounts, items, etc.)
Priority Ranking:
- 1. Permanent cosmetic purchases (name color, if desired)
- 2. Utility purchases with gameplay impact (varies by server)
- 3. Inn Coupons (low priority, nice-to-have convenience)
Inn Coupons: where you visit Percy Weasley at the Prefect's Lounge (lodge.php) and exchange 30 donation points (default cost setting) for a card reading "Coupon: Good for ten free stays at [inn name]," storing the 10 stays in your availablestays preference which accumulates indefinitely (buy 3 packages = 30 total stays, no expiration). At the inn, instead of choosing a room type and paying gold (typically ~90 gold for standard room), you see navigation like "Show him your coupon for X inn stays" (grammar adjusts: 1="stay" singular, 2-10="stays" plural, 11+="coupons" plural) which when clicked runs runmodule.php?module=inncoupons&op=room to decrement availablestays by 1, set loggedin=0 (log you out), location=[inn name], boughtroomtoday=1 (prevent double room purchase), restorepage="inn.php?op=strolldown" (standard inn wakeup page), saveuser(), and redirect to index.php for logout — producing EXACTLY the same effect as paying for an inn room (advance to newday, wake up at inn) except you spent 0 gold (coupon consumed instead). The module includes legacy migration code checking donationconfig['innstays'] and converting to the newer availablestays pref system, hooks pointsdesc to display "The cost for ten free stays at the inn is 30 points" in lodge descriptions, and is fundamentally a low-cost utility purchase converting donation points (acquired via real-world donations or special events) into ongoing gold savings (10 rooms × inn cost = ~900 gold saved) plus the convenience of one-click sleeping without gold transactions. It's not a high-priority lodge purchase compared to permanent cosmetics like name colorization (2000-5000 points), but it's a reasonable use of excess donation points if you value convenience and long-term gold savings.