rom24-quickmud-python 2.9.16__py3-none-any.whl → 2.9.18__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mud/commands/communication.py +16 -8
- mud/commands/shop.py +11 -0
- {rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/METADATA +1 -1
- {rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/RECORD +8 -8
- {rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/WHEEL +0 -0
- {rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/entry_points.txt +0 -0
- {rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/licenses/LICENSE +0 -0
- {rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/top_level.txt +0 -0
mud/commands/communication.py
CHANGED
|
@@ -165,13 +165,18 @@ def do_say(char: Character, args: str) -> str:
|
|
|
165
165
|
asyncio.create_task(send_to_char(listener, per_message))
|
|
166
166
|
if hasattr(listener, "messages"):
|
|
167
167
|
listener.messages.append(per_message)
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
168
|
+
# mirroring ROM src/act_comm.c:779 — `if (!IS_NPC (ch))` gate.
|
|
169
|
+
# Only PC speakers enter the SPEECH listener loop; this prevents
|
|
170
|
+
# mob-to-mob speech-trigger cascades (mob A says "X" → mob B's
|
|
171
|
+
# SPEECH trigger fires → triggers another say → infinite loop).
|
|
172
|
+
if not getattr(char, "is_npc", False):
|
|
173
|
+
for mob in list(char.room.people):
|
|
174
|
+
if mob is char or not getattr(mob, "is_npc", False):
|
|
175
|
+
continue
|
|
176
|
+
default_pos = getattr(mob, "default_pos", getattr(mob, "position", Position.STANDING))
|
|
177
|
+
if getattr(mob, "position", default_pos) != default_pos:
|
|
178
|
+
continue
|
|
179
|
+
mobprog.mp_speech_trigger(args, mob, char)
|
|
175
180
|
return f"{{6You say '{{7{args}{{6'{{x"
|
|
176
181
|
|
|
177
182
|
|
|
@@ -215,7 +220,10 @@ def do_tell(char: Character, args: str) -> str:
|
|
|
215
220
|
if buffered_response:
|
|
216
221
|
return buffered_response
|
|
217
222
|
|
|
218
|
-
if
|
|
223
|
+
# mirroring ROM src/act_comm.c:946 — `if (!IS_NPC (ch) && IS_NPC (victim)
|
|
224
|
+
# && HAS_TRIGGER (victim, TRIG_SPEECH))`. NPC tellers do not fire SPEECH
|
|
225
|
+
# triggers on NPC targets; same anti-cascade gate as do_say.
|
|
226
|
+
if not getattr(char, "is_npc", False) and getattr(target, "is_npc", False):
|
|
219
227
|
default_pos = getattr(target, "default_pos", getattr(target, "position", Position.STANDING))
|
|
220
228
|
if getattr(target, "position", default_pos) == default_pos:
|
|
221
229
|
mobprog.mp_speech_trigger(message, target, char)
|
mud/commands/shop.py
CHANGED
|
@@ -833,6 +833,17 @@ def do_buy(char: Character, args: str) -> str:
|
|
|
833
833
|
char.messages.append("You haggle with the shopkeeper.")
|
|
834
834
|
check_improve(char, "haggle", True, 4)
|
|
835
835
|
|
|
836
|
+
# ROM src/act_obj.c:2734-2745 — broadcast `$n buys $p[N].` or `$n buys $p.`
|
|
837
|
+
# to the room before deducting cost so onlookers see the transaction.
|
|
838
|
+
room = getattr(char, "room", None)
|
|
839
|
+
if room is not None:
|
|
840
|
+
buyer_name = char.short_descr or char.name or "Someone"
|
|
841
|
+
item_name = selected_obj.short_descr or selected_obj.name or "something"
|
|
842
|
+
if quantity > 1:
|
|
843
|
+
room.broadcast(f"{buyer_name} buys {item_name}[{quantity}].", exclude=char)
|
|
844
|
+
else:
|
|
845
|
+
room.broadcast(f"{buyer_name} buys {item_name}.", exclude=char)
|
|
846
|
+
|
|
836
847
|
deduct_cost(char, total_cost)
|
|
837
848
|
_set_keeper_total_wealth(keeper, _keeper_total_wealth(keeper) + total_cost)
|
|
838
849
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: rom24-quickmud-python
|
|
3
|
-
Version: 2.9.
|
|
3
|
+
Version: 2.9.18
|
|
4
4
|
Summary: A modern Python port of the ROM 2.4b6 MUD engine with full telnet server and JSON world loading
|
|
5
5
|
Author-email: Mark Jedrzejczyk <mark.jedrzejczyk@gmail.com>
|
|
6
6
|
Maintainer-email: Mark Jedrzejczyk <mark.jedrzejczyk@gmail.com>
|
|
@@ -49,7 +49,7 @@ mud/commands/build.py,sha256=jro60oQm_q1RPWKrz-5QsdchYxItUDHcaZ_9Tm06qJU,152434
|
|
|
49
49
|
mud/commands/channels.py,sha256=1PewUVrMk1Uh7dUj7ZZgUyL9xkQbSN7BY9KtBkL4GAc,1584
|
|
50
50
|
mud/commands/character.py,sha256=my8wNr6Z0RA9lSwfv8HkExOw7VKfFVgQe_PQ70dps8M,6539
|
|
51
51
|
mud/commands/combat.py,sha256=T22a3xYviTEsK71zYdAnaHk3CPxpYyV05crunpDBr24,34017
|
|
52
|
-
mud/commands/communication.py,sha256=
|
|
52
|
+
mud/commands/communication.py,sha256=oOCZIq5YoI4gSAvf7FzyT-QxhDO0EYlo3EroChNuQPA,26804
|
|
53
53
|
mud/commands/compare.py,sha256=o6kalHONN15J6lvFzrE7-bcYvVhIY2KCHXlCvFH3T-0,4168
|
|
54
54
|
mud/commands/consider.py,sha256=rQwLTZq28nfdpnBmEgpV72FSvJJE5JPuPMhtMouN-hE,2230
|
|
55
55
|
mud/commands/consumption.py,sha256=SW6ikVuAAY1C9jMv3v4kgApPOV324TkABBtFQ6pjSlE,14241
|
|
@@ -91,7 +91,7 @@ mud/commands/player_info.py,sha256=VqEHgETh7u1BMVWJDIMhvBgF2Pm5LGNtNpLRTbXt3mI,7
|
|
|
91
91
|
mud/commands/position.py,sha256=uwphiwxN_sEGi2wlAD5oE2pmlPCe1y9f50g_HrARg58,16339
|
|
92
92
|
mud/commands/remaining_rom.py,sha256=nIDH2XiMyxm-vR45QX6BLwdIdaS4V0kNEhm5mFY79hU,18780
|
|
93
93
|
mud/commands/session.py,sha256=hrx-HY94JkEed64FPSe6TbfcVITXlsfzQ9DLDQ9ZYjY,14865
|
|
94
|
-
mud/commands/shop.py,sha256=
|
|
94
|
+
mud/commands/shop.py,sha256=u2uFM6qBqlxGTw-qAGPj3ph8jb5qqyX77Dk2TkIocKo,40698
|
|
95
95
|
mud/commands/socials.py,sha256=IKSo1n-9aCtMDJFEq9KVBQIeabbijeMOZDXZUGoT_us,4401
|
|
96
96
|
mud/commands/thief_skills.py,sha256=OJ2rT1Z56Pm1zHeaN5NvWCa4g2xT_k7epJNQR7JpYMM,15161
|
|
97
97
|
mud/commands/typo_guards.py,sha256=NDL-6n1KwUduJNKpx_vRv3qGVrA1TvYelBwcla_RU9g,1434
|
|
@@ -216,9 +216,9 @@ mud/world/obj_find.py,sha256=tgnUkbFjnCl586Lzl6yRzCmllZSNEfQpQlrxCMVcUGU,5295
|
|
|
216
216
|
mud/world/time_persistence.py,sha256=K4uhRpu08IDHY5uReBYTvw4BHuqsSxWvbv-h1VsPvf8,1663
|
|
217
217
|
mud/world/vision.py,sha256=NRk3cvrGyyldU4W98qAVlYZp9wL-IUE1dTgk6DpM-NA,11609
|
|
218
218
|
mud/world/world_state.py,sha256=3KpiDP6v24sZDn9-g44UypXpegzgRShHo1XvektJzdU,8810
|
|
219
|
-
rom24_quickmud_python-2.9.
|
|
220
|
-
rom24_quickmud_python-2.9.
|
|
221
|
-
rom24_quickmud_python-2.9.
|
|
222
|
-
rom24_quickmud_python-2.9.
|
|
223
|
-
rom24_quickmud_python-2.9.
|
|
224
|
-
rom24_quickmud_python-2.9.
|
|
219
|
+
rom24_quickmud_python-2.9.18.dist-info/licenses/LICENSE,sha256=anQ2j9As6sIC8tZgQCXbo0-09JDH9vPiqhA9djnOvkY,1078
|
|
220
|
+
rom24_quickmud_python-2.9.18.dist-info/METADATA,sha256=Gath7nkg7vP0AgqOnrU6xmSEiNQg1HFEFGo1sn5CBQU,15671
|
|
221
|
+
rom24_quickmud_python-2.9.18.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
|
|
222
|
+
rom24_quickmud_python-2.9.18.dist-info/entry_points.txt,sha256=VFru08UQTXZA_CkK-NBjJmWHyEX5a3864fQHjhaojbw,41
|
|
223
|
+
rom24_quickmud_python-2.9.18.dist-info/top_level.txt,sha256=Fk1WPmabIIjp7_iZXLYpbAVqiq7lG7TeAHt30AsOKtQ,4
|
|
224
|
+
rom24_quickmud_python-2.9.18.dist-info/RECORD,,
|
|
File without changes
|
{rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/entry_points.txt
RENAMED
|
File without changes
|
{rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|
{rom24_quickmud_python-2.9.16.dist-info → rom24_quickmud_python-2.9.18.dist-info}/top_level.txt
RENAMED
|
File without changes
|