home
·
contact
·
privacy
projects
/
plomrogue
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Server: Fix AI bug (searching too costly consumable when not player).
[plomrogue]
/
server
/
ai.py
diff --git
a/server/ai.py
b/server/ai.py
index 415d533a5b70603c56eec796dd8f24df5d2991be..661d3022acefdeba50460ff4134d4adf3c61084f 100644
(file)
--- a/
server/ai.py
+++ b/
server/ai.py
@@
-140,9
+140,8
@@
def get_dir_to_target(t, filter):
[set_map_score(mt[1] * maplen + mt[2], 0)
for mt in t["T_MEMTHING"]
if ord_blank != t["T_MEMMAP"][mt[1] * maplen + mt[2]]
[set_map_score(mt[1] * maplen + mt[2], 0)
for mt in t["T_MEMTHING"]
if ord_blank != t["T_MEMMAP"][mt[1] * maplen + mt[2]]
- if t != world_db["Things"][0] or
- (world_db["ThingTypes"][mt[0]]["TT_TOOL"] == "food" and
- world_db["ThingTypes"][mt[0]]["TT_TOOLPOWER"] > eat_cost)]
+ if world_db["ThingTypes"][mt[0]]["TT_TOOL"] == "food"
+ if world_db["ThingTypes"][mt[0]]["TT_TOOLPOWER"] > eat_cost]
elif "s" == filter:
zero_score_map_where_char_on_memdepthmap(mem_depth_c[0])
if "f" == filter:
elif "s" == filter:
zero_score_map_where_char_on_memdepthmap(mem_depth_c[0])
if "f" == filter: