Update username parsing

- Update username parsing
- [ramenkan] Include one meat definitively in !ramen output
- [ramenkan] Add tsukemen and other data
trunk
mio 2 years ago
parent 188c96a62c
commit 16be6d9dda

@ -122,7 +122,7 @@ class IRC:
data["req_chan"] = line.split("PRIVMSG ", \
1)[1].split(" :", 1)[0]
data["nick"] = line.split("!~", 1)[0][1:]
data["user"] = line.split("!~", 2)[1][0:].split("@", 1)[0]
data["user"] = line.split("!~", 2)[0][0:].split("@", 1)[0]
return data
def listen(self, context, trigger, handler, *args, **kwargs):

@ -73,11 +73,16 @@ class Ramen:
dish = self.dishes
# Check vegetarian flag
is_veggie = kwargs.get("veggie", False)
combo = "ramen in "
# Noodle type and broth richness
if randint(0, 1):
combo = self.rand(dish["noodle-shape"]) + ", " + \
self.rand(dish["noodle-broth-type"]) + " "
# 20% chance of tsukemen
roll = randint(1, 10)
if roll <= 2:
combo = "tsukemen from "
else:
combo = "ramen in "
# Noodle type and broth richness
if randint(0, 1):
combo = self.rand(dish["noodle-shape"]) + ", " + \
self.rand(dish["noodle-broth-type"]) + " "
combo = combo.capitalize()
# Broth type
if is_veggie:
@ -92,7 +97,7 @@ class Ramen:
if is_veggie:
prev_top = self.rand(dish["topping"])
else:
prev_top = self.rand(dish["topping"] + dish["meat"])
prev_top = self.rand(dish["meat"])
combo += " with " + prev_top
else:
if n > 2 and n < n_top:
@ -102,9 +107,14 @@ class Ramen:
if is_veggie:
next_top = self.rand(dish["topping"])
else:
next_top = self.rand(dish["topping"])
# 20% chance of egg topping
roll = randint(1, 10)
if roll <= 2:
next_top = self.rand(dish["topping-egg"])
else:
next_top = self.rand(dish["topping"])
# Check for duplicate
if next_top == prev_top:
while next_top in prev_top:
next_top = self.rand(dish["topping"])
combo += next_top
prev_top = next_top

@ -1,16 +1,19 @@
# Lists of ingredients to assemble a ramen dish
broth:
- Kobe beef bone
- pork bone
- chicken and pork bone
- niboshi and pork bone # dried little sardines
- seafood, chicken and pork bone
- chicken, pork bone, tuna and kelp
- tonkotsu
- pork bone and chicken
- pork bone and niboshi # dried little sardines
- pork bone, chicken and seafood
- pork bone, chicken, tuna and kelp
- pork bone and soy sauce
- chicken
- chicken, katsuo and konbu # skipjack tuna and kelp
- fish
- gyokai # dried anchovies/shrimp/squid/seaweed
- gyokai tonkotsu
- roasted tuna
- miso and truffle # (from chef Ryu Takahashi)
- milk
- curry and milk
@ -34,10 +37,11 @@ noodle-shape:
condiment:
- butter
- chili oil
- rayu # Japanese chili oil
- rayu # chili oil
- chili peppers
- chili sauce
- mayu # garlic oil
- spicy garlic and ginger oil
- sesame oil
- dashi # fish and seaweed stock
- white pepper
@ -69,15 +73,19 @@ topping:
- scallions
- boiled spinach
meat:
topping-egg:
- a raw egg
- a seasoned boiled egg
- raw eggs
- an ajitama # egg marinated in soy sauce
meat:
- Kobe beef fillet
- Kobe beef sirloin
- wagyu
- teppanyaki beef
- beef shank
- chicken breast
- chicken meatballs
- teppanyaki chicken
- crab
- crispy duck
@ -85,7 +93,7 @@ meat:
- kamaboko # fish paste/surimi
- narutomaki # fish paste with swirling pattern
- kakuni # cubed braised pork
- barbecued pork # chashu
- chashu # Japanese-style barbequed pork
- pork confit
- pork cutlet
- pork belly
@ -113,7 +121,7 @@ tapa-veggie:
set:
- Korean kimchi ramyeon with tteok
- Vancouver beer ramen (cold bonito broth ramen with egg whites)
- Vancouver cold bonito beer broth ramen with egg whites
- Hakata tonkotsu ramen with pickled mustard greens
- Hakodate shio ramen with kelp, crab, shrimp, sea urchin and scallops
- Hakodate shrimp ramen with a hard-boiled egg and white onions
@ -121,6 +129,7 @@ set:
- Kitakata niboshi-tonkotsu ramen with chashu, naruto and spring onions
- Kumamoto tonkotsu ramen with chashu, raw eggs, scallions and garlic chips
- Muroran curry ramen with chashu, wakame and bean sprouts
- Nagasaki champon with fried pork, scallions and seasonal greens
- Osaka Kobe beef sirloin ramen with a soft-boiled egg and arugula
- Sapporo miso ramen with scallops, sweet corn and bean sprouts
- Tokyo ramen in chicken broth with pork, menma, a boiled egg and nori

Loading…
Cancel
Save