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:
2f7c446
)
Server: Minor code simplification.
author
Christian Heller
<c.heller@plomlompom.de>
Thu, 3 Mar 2016 02:17:51 +0000
(
03:17
+0100)
committer
Christian Heller
<c.heller@plomlompom.de>
Thu, 3 Mar 2016 02:17:51 +0000
(
03:17
+0100)
server/ai.py
patch
|
blob
|
history
diff --git
a/server/ai.py
b/server/ai.py
index db40625659d00878ef866e467d6973c09ee563e7..21f7115a3e941dd29ebbc3d2cec654e1cb6c540d 100644
(file)
--- a/
server/ai.py
+++ b/
server/ai.py
@@
-64,8
+64,7
@@
def get_dir_to_target(t, filter):
return False
def good_flee_target(m):
- own_corpse_id = world_db["ThingTypes"][t["T_TYPE"]]["TT_CORPSE_ID"]
- corpse_type = world_db["ThingTypes"][own_corpse_id]
+ corpse_type = world_db["ThingTypes"][tt["TT_CORPSE_ID"]]
targetness = 0 if corpse_type["TT_TOOL"] != "food" \
else corpse_type["TT_TOOLPOWER"]
type = world_db["ThingTypes"][m["T_TYPE"]]