Abigail the Street Hawker

Village/Gardens encounter where diminutive elf street vendor Abigail ambushes you to sell romantic gifts for your partner/spouse. Purchase costs 2 gems (cost setting, default). 80% chance partner likes gift at newday (charmchance setting, +2 charm), 20% dislikes it (-2 charm). Once per day (bought pref). Gender-specific gifts: male partners get cufflinks/boots/watches/leather items, female partners get earrings/slippers/necklaces/flowers, nonbinary/custom get books/backpacks/scarves/plush toys. Gift delivered immediately by messenger, charm outcome next newday. Can yell at Abigail to leave you alone for 10 days (angry pref). 50% raw event chance. Requires Lovers module (marriedto). Where an elf sales representative harasses you on the street and forces you to buy presents to prove your love, then there's a coin flip whether your partner thinks you're thoughtful or cheap, and if you get annoyed and shout at the elf she gets offended and ghosts you for 10 days.

Location & Access

Where: Village and Gardens event hooks. 50% raw chance (bought pref blocks after purchase). Once per day reset at newday. Requires Lovers module (partner system).

Requirements:

  • Must have partner/spouse (Lovers module marriedto != 0 and != INT_MAX)
  • Haven't purchased gift today (bought pref == 0)
  • Not currently angry (angry pref == 0, Abigail avoids you if > 0)

The Encounter

Abigail's Appearance: "While you are wandering idly, minding your own business, you are approached by a diminutive elf in a green cloak." Not subtle. She knows what she's doing.

Sales Pitch: "'Happy Day to you! Can I interest you in a lovely [gift] for somebody special? It's a fine gift, crafted with care and skill! And, for you, only [cost] gems!'" Aggressive direct marketing.

Gift Selection: Abigail offers ONE random gift appropriate for your partner's gender (session['user']['sex']). The gift is randomly selected when event triggers and stored in trinket pref.

Your Options:

  • Purchase this gift: Buy for cost gems (default 2), gift delivered to partner
  • Don't buy anything: Politely decline ("You're sure that [partner] wouldn't like something like that, anyway")
  • Shout at Abigail: Yell at her to leave you alone (she gets offended, avoids you for 10 days)

Gift Categories by Gender

For Male Partners (SEX_FEMALE = 0):

  • Pair of cufflinks
  • Leather belt
  • Hat
  • Pair of boots
  • Pocket watch
  • Silver flask
  • Leather jacket

For Female Partners (SEX_MALE = 1):

  • Pair of earrings
  • Pair of satin slippers
  • Jeweled necklace
  • Pretty bracelet
  • Bouquet of flowers
  • Silk scarf
  • Perfume

For Nonbinary/Custom Partners (SEX_NONBINARY = 2, SEX_CUSTOM = 3):

  • Book
  • Beautiful sketchpad
  • Stylish backpack
  • Handmade bracelet
  • Plush toy
  • Colorful scarf
  • Unique keychain

Hook for Custom Gifts: Modules can add gifts via "abigail-gifts" hook (array['gifts'][gender] structure).

Purchase & Delivery

Cost Check: Must have enough gems. If insufficient:

  • 0 gems: "Abigail stares at your empty hand."
  • 1 gem (need 2): "Abigail stares at the single gem in your hand."
  • Insufficient: "How can you buy [partner] a gift without enough gems?"
  • Option to "Walk Away" ("Not having any gems to buy a gift for [partner], you wander sadly away")

Purchase Success:

  • Spend cost gems (default: 2)
  • Set bought pref = 1 (blocks repeat today)
  • Delivery: "Abigail promises to have the [gift] delivered to [partner] right away."
  • Anticipation: "You can't wait to find out what [partner] thinks of the gift!"

System Mail: If marriedto is valid (!= 0 and != INT_MAX), partner receives systemmail: Subject "`%Abigail has delivered a gift to you!", Body: "[Your name] has delivered a [gift] as a gift."

Like/Dislike Roll: e_rand(1,100) vs charmchance setting (default 80):

  • Roll ≤ 80: liked pref incremented (partner will like gift at newday)
  • Roll > 80: liked pref = -1 (partner will dislike gift at newday)

Newday Outcome

Partner Response: If bought == 1 (purchased gift yesterday), messenger delivers note from partner:

They Liked It (liked pref == 1):

  • Message: "'What a wonderful surprise! Your gift was very thoughtful! I shall show everyone!'"
  • Reward: "`^You gain some charm!`n" → +2 charm

They Hated It (liked pref != 1):

  • Message: "'I can't believe you think you can win my approval with a cheap gift like that!'"
  • Penalty: "`^You `$lose`^ some charm.`n" → -2 charm (minimum 0, won't go negative)

Cleanup: liked pref reset to 0, bought pref reset to 0 (unless angry > 0, then bought stays 1 to block event).

Shouting at Abigail

What Happens: If you choose "Shout at Abigail":

  • "Abigail just shakes her head and leaves!`n"
  • "You feel a great relief."
  • angry pref set to 10 (10 days of avoidance)
  • bought pref set to 1 (blocks event from triggering)

Angry Countdown:

  • Each newday: angry pref decrements by 1 (if > 0)
  • While angry > 0: bought pref forced to 1 (event won't trigger)
  • After 10 days: angry reaches 0, bought reset to 0, Abigail may approach again

Strategic Use: Yelling at Abigail gives 10 days of peace from street harassment. No immediate penalty. Use if you're gem-poor or don't care about charm.

Strategy

Expected Value:

  • 80% chance: +2 charm (gain 1.6 charm on average)
  • 20% chance: -2 charm (lose 0.4 charm on average)
  • Net expected: +1.2 charm per purchase
  • Cost: 2 gems (default)

When to Buy:

  • You have spare gems (2+ available)
  • You want charm gains (for charm-gated content or roleplay)
  • You enjoy the partnership roleplay element
  • Expected value is positive (+1.2 charm for 2 gems = 0.6 charm per gem)

When to Decline/Yell:

  • Gems scarce (save for more valuable purchases)
  • Charm not important to your build
  • Don't want daily interruption (yell for 10-day respite)
  • 20% downside risk unacceptable if charm is low

Optimization:

  • Always buy if gems abundant and charm desired (favorable odds)
  • Yelling is free "disable module for 10 days" option
  • No penalty for politely declining (just move on)

Admin Configuration

Settings:

  • cost: Number of gems items cost (int, default: 2)
  • charmchance: % chance partner likes gift (range 5-100 in 5% increments, default: 80)

User Preferences:

  • bought: Purchased gift today? (bool, default: 0) — Blocks repeat visits
  • trinket: Last gift offered? (string, default: "boots") — Stores what Abigail showed
  • liked: Liked gift from lover (bool, default: 0) — Determines charm outcome
  • angry: Abigail avoids user for X days (int, default: 0) — Countdown from yelling

Technical Details

Hooks Used:

  • newday: Reset bought pref, decrement angry, show partner's response to gift
  • village: 50% event chance if bought == 0
  • gardens: 50% event chance if bought == 0 (same event in both locations)

Event Weight Function:

$bought = get_module_pref("bought", "abigail");
return ($bought ? 0 : 50);

Returns 50 if not bought today, 0 if already bought (blocks event).

Gift Selection Logic:

// Get partner's gender
$session['user']['sex'] // 0=female, 1=male, 2=nonbinary, 3=custom

// Select random gift from gender-appropriate array
$trinket = $gifts[$session['user']['sex']][e_rand(0, count($gifts[$session['user']['sex']])-1)];

Charm Modification Safety: When losing charm, code checks: if ($session['user']['charm'] > 2) { charm -= 2; } else { charm = 0; } — Prevents negative charm.

Lovers Module Integration

Requirements: Abigail module requires "lovers" version 1.0 (core_module). Uses get_partner() function.

Partner Display: All messages reference partner name in backticks: `^[partner]` where [partner] is from get_partner(true).

Marriedto Validation:

  • System mail only sent if $session['user']['marriedto'] != INT_MAX && != 0
  • If marriedto is INT_MAX (no partner) or 0 (unknown state), mail skipped
  • Gift still purchased and charm outcome still occurs (partner name displayed but mail not sent)

Gender Flexibility: Updated to support nonbinary (SEX_NONBINARY) and custom (SEX_CUSTOM) genders. If sex < 0 or > 3, defaults to SEX_CUSTOM.

Lore & Roleplay

Abigail's Character: Diminutive elf (small in stature), wears green cloak, street vendor/hawker. Persistent and pushy sales tactics. "Happy Day to you!" greeting. Promises quick delivery.

The Sales Tactic: Abigail targets you "while you are wandering idly, minding your own business" — classic ambush marketing. Shows you ONE item, claims it's perfect for your partner, applies pressure with "for YOU, only [cost] gems!" language.

Partner Reactions:

  • Positive: Thoughtful, wonderful surprise, showing it to everyone (pride/joy)
  • Negative: "Cheap gift" accusation, can't buy approval with trinkets (offended/disappointed)

Yelling Reaction: Abigail "shakes her head" (disappointment/judgment), leaves silently. You feel "great relief" (freedom from sales pressure). She avoids you for 10 days (holding a grudge).

Thematic Elements: Gift-giving as love language, consumer capitalism in magical world, relationship maintenance via material goods, anxiety of gift selection, vulnerability of romantic gestures.

Common Questions

Q: What if I don't have a partner?
A: Event won't trigger if marriedto is invalid (INT_MAX or 0). Requires Lovers module with active partnership.

Q: Can I buy multiple gifts per day?
A: No. bought pref blocks repeat purchases same day. Resets at newday.

Q: What happens if I shout at Abigail multiple times?
A: Each time you yell, angry pref resets to 10. She'll avoid you for 10 more days from that point.

Q: Can I choose which gift to buy?
A: No. Abigail selects ONE random gift from partner's gender category. Take it or leave it.

Q: Does my partner see the gift in their inventory?
A: No. It's narrative/lore only. They receive system mail notification, charm outcome happens at your newday.

Q: What if I have 0 charm and get the negative outcome?
A: Charm can't go below 0. Code sets to 0 if would go negative. Safe to try even with low charm.

Abigail the Street Hawker: where a sales-aggressive elf in a green cloak accosts you on the street corner like you're trying to walk past a perfume kiosk at the mall, pressures you into buying random romantic gifts for your significant other with money you don't have, delivers them via messenger bird before you can change your mind, and then the next morning there's an 80% chance your partner thinks you're thoughtful and a 20% chance they call it cheap garbage and your self-esteem drops, but honestly the best part is you can just yell at the elf and she'll leave you alone for 10 days which is the closest thing to an unsubscribe button this module offers.