atagen

jelq

public

an http based roguelike rpg about jelqing

Star0
Watch0
bf5f8cb6f60f6e974991335cdfec63b7874a37bf
1
ssh://brewery@pls.lobotomise.me:33/atagen/jelq.git
src/game/items.rsRust156 lines5.1 KB
1
#[derive(Clone, Copy, PartialEq, Eq, Debug)]
2
pub enum Item {
3
    WarmTowel,
4
    IcePack,
5
    Ruler,
6
    DoorLock,
7
    DndSign,
8
    Blinds,
9
    Pump,
10
    PumpPro,
11
    Extender,
12
    Ring,
13
    Supplement,
14
    Cage,
15
    CageKey,
16
    Spreadsheet,
17
    TeapotSpout,
18
    BabyOil,
19
    CoconutOil,
20
    Lotion,
21
    Vaseline,
22
    EnergyDrink,
23
}
24
25
pub const SHOP: [Item; 15] = [
26
    Item::Pump,
27
    Item::PumpPro,
28
    Item::Extender,
29
    Item::Ring,
30
    Item::Supplement,
31
    Item::DoorLock,
32
    Item::DndSign,
33
    Item::Blinds,
34
    Item::Ruler,
35
    Item::IcePack,
36
    Item::CageKey,
37
    Item::BabyOil,
38
    Item::CoconutOil,
39
    Item::Lotion,
40
    Item::Vaseline,
41
];
42
43
impl Item {
44
    pub(super) const ALL: [Self; 20] = [
45
        Self::WarmTowel,
46
        Self::IcePack,
47
        Self::Ruler,
48
        Self::DoorLock,
49
        Self::DndSign,
50
        Self::Blinds,
51
        Self::Pump,
52
        Self::PumpPro,
53
        Self::Extender,
54
        Self::Ring,
55
        Self::Supplement,
56
        Self::Cage,
57
        Self::CageKey,
58
        Self::Spreadsheet,
59
        Self::TeapotSpout,
60
        Self::BabyOil,
61
        Self::CoconutOil,
62
        Self::Lotion,
63
        Self::Vaseline,
64
        Self::EnergyDrink,
65
    ];
66
67
    pub fn slug(self) -> &'static str {
68
        match self {
69
            Self::WarmTowel => "warm-towel",
70
            Self::IcePack => "ice-pack",
71
            Self::Ruler => "ruler",
72
            Self::DoorLock => "door-lock",
73
            Self::DndSign => "do-not-disturb-sign",
74
            Self::Blinds => "window-blinds",
75
            Self::Pump => "pump",
76
            Self::PumpPro => "pump-pro",
77
            Self::Extender => "extender",
78
            Self::Ring => "cock-ring",
79
            Self::Supplement => "supplement",
80
            Self::Cage => "chastity-cage",
81
            Self::CageKey => "cage-key",
82
            Self::Spreadsheet => "spreadsheet",
83
            Self::TeapotSpout => "teapot-spout",
84
            Self::BabyOil => "baby-oil",
85
            Self::CoconutOil => "coconut-oil",
86
            Self::Lotion => "lotion",
87
            Self::Vaseline => "vaseline",
88
            Self::EnergyDrink => "energy-drink",
89
        }
90
    }
91
92
    pub fn parse(slug: &str) -> Option<Self> {
93
        Self::ALL.into_iter().find(|item| item.slug() == slug)
94
    }
95
96
    pub fn description(self) -> &'static str {
97
        match self {
98
            Self::WarmTowel => {
99
                "Reusable. Satisfies the warm-up precondition. Use technique=warmup."
100
            }
101
            Self::IcePack => "Lowers EQ by 40. Use technique=ice.",
102
            Self::Ruler => "Measures honestly. The length resource now carries a Content-Length.",
103
            Self::DoorLock => "Keeps your brother out once.",
104
            Self::DndSign => "Works on housekeeping. Mum does not read signs.",
105
            Self::Blinds => "The neighbour has a good camera. The blinds are better.",
106
            Self::Pump => "A pump.",
107
            Self::PumpPro => "Use technique=pump. Gains are temporary.",
108
            Self::Extender => "Passive gains each turn. Takes up room. Can be removed with DELETE.",
109
            Self::Ring => {
110
                "Girth gains doubled. Rupture risk raised. Responses are compressed if you accept gzip. Can be removed with DELETE."
111
            }
112
            Self::Supplement => "Use technique=supplement.",
113
            Self::Cage => "Locked.",
114
            Self::CageKey => "Pump-Bro does not ask.",
115
            Self::Spreadsheet => "Charts your progress. Every line is flat.",
116
            Self::TeapotSpout => "Does nothing. Cannot be dropped.",
117
            Self::BabyOil => "Smooth. +1. One unit per jelq.",
118
            Self::CoconutOil => "+3. Solid until it matters. Suspicious at Nan's.",
119
            Self::Lotion => "Handy. +0, and it chafes, so each jelq costs an extra stamina.",
120
            Self::Vaseline => "+2. Raises suspicion everywhere.",
121
            Self::EnergyDrink => "technique=energy. +3 stamina. Tastes like a battery.",
122
        }
123
    }
124
125
    pub fn pitch(self) -> &'static str {
126
        match self {
127
            Self::PumpPro => "A pump, but professional.",
128
            Self::Extender => "Passive gains every turn. Takes up room.",
129
            Self::Ring => "Doubles girth gains. Pump-Bro does not discuss the risks.",
130
            Self::Supplement => "Clinically formulated. Ships from overseas.",
131
            Self::DndSign => "Housekeeping respects it.",
132
            Self::Blinds => "The neighbour has a good camera.",
133
            Self::Ruler => "Pump-Bro does not recommend it.",
134
            Self::IcePack => "Cold.",
135
            _ => self.description(),
136
        }
137
    }
138
139
    pub fn price(self) -> Option<u32> {
140
        match self {
141
            Self::Pump => Some(10),
142
            Self::PumpPro | Self::Extender | Self::CageKey => Some(15),
143
            Self::Ring => Some(8),
144
            Self::Supplement | Self::DoorLock | Self::DndSign | Self::Blinds | Self::Ruler => {
145
                Some(5)
146
            }
147
            Self::BabyOil | Self::CoconutOil | Self::Lotion | Self::Vaseline => Some(4),
148
            Self::IcePack => Some(3),
149
            Self::WarmTowel
150
            | Self::Cage
151
            | Self::Spreadsheet
152
            | Self::TeapotSpout
153
            | Self::EnergyDrink => None,
154
        }
155
    }
156
}