home
·
contact
·
privacy
projects
/
plomrogue
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
422c426
)
Fix bug in dying actor dropping Things: Unset "carried" flag on event.
author
Christian Heller
<c.heller@plomlompom.de>
Tue, 10 Mar 2015 22:10:48 +0000
(23:10 +0100)
committer
Christian Heller
<c.heller@plomlompom.de>
Tue, 10 Mar 2015 22:10:48 +0000
(23:10 +0100)
roguelike-server
patch
|
blob
|
history
diff --git
a/roguelike-server
b/roguelike-server
index 0bc77cc4bb8dcb0f67560e41c8956e33e6accdfb..707a5fdbf048d28e02a2dcbebb06bdc635e9f8c9 100755
(executable)
--- a/
roguelike-server
+++ b/
roguelike-server
@@
-589,12
+589,13
@@
def decrement_lifepoints(t):
t["T_LIFEPOINTS"] -= 1
world_db["GOD_MOOD"] -= 1 # #
if 0 == t["T_LIFEPOINTS"]:
t["T_LIFEPOINTS"] -= 1
world_db["GOD_MOOD"] -= 1 # #
if 0 == t["T_LIFEPOINTS"]:
+ sadness = world_db["ThingTypes"][t["T_TYPE"]]["TT_LIFEPOINTS"] # #
+ world_db["GOD_MOOD"] -= sadness # #
for id in t["T_CARRIES"]:
t["T_CARRIES"].remove(id)
world_db["Things"][id]["T_POSY"] = t["T_POSY"]
world_db["Things"][id]["T_POSX"] = t["T_POSX"]
for id in t["T_CARRIES"]:
t["T_CARRIES"].remove(id)
world_db["Things"][id]["T_POSY"] = t["T_POSY"]
world_db["Things"][id]["T_POSX"] = t["T_POSX"]
- sadness = world_db["ThingTypes"][t["T_TYPE"]]["TT_LIFEPOINTS"] # #
- world_db["GOD_MOOD"] -= sadness # #
+ world_db["Things"][id]["carried"] = False
t["T_TYPE"] = world_db["ThingTypes"][t["T_TYPE"]]["TT_CORPSE_ID"]
if world_db["Things"][0] == t:
t["fovmap"] = bytearray(b' ' * (world_db["MAP_LENGTH"] ** 2))
t["T_TYPE"] = world_db["ThingTypes"][t["T_TYPE"]]["TT_CORPSE_ID"]
if world_db["Things"][0] == t:
t["fovmap"] = bytearray(b' ' * (world_db["MAP_LENGTH"] ** 2))