py2hackCraft2 1.0.18__tar.gz → 1.0.20__tar.gz
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.
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/PKG-INFO +1 -1
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/README.md +4 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft/modules.py +45 -6
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft2.egg-info/PKG-INFO +1 -1
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/setup.py +1 -1
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft/__init__.py +0 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft/material.py +0 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft2.egg-info/SOURCES.txt +0 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft2.egg-info/dependency_links.txt +0 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft2.egg-info/requires.txt +0 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/py2hackCraft2.egg-info/top_level.txt +0 -0
- {py2hackcraft2-1.0.18 → py2hackcraft2-1.0.20}/setup.cfg +0 -0
|
@@ -161,6 +161,17 @@ class Coordinates:
|
|
|
161
161
|
relative = "~"
|
|
162
162
|
local = "^"
|
|
163
163
|
|
|
164
|
+
class Side:
|
|
165
|
+
"""
|
|
166
|
+
ブロックの配置方向を表すデータクラス
|
|
167
|
+
"""
|
|
168
|
+
right = "Right"
|
|
169
|
+
left = "Left"
|
|
170
|
+
front = "Front"
|
|
171
|
+
back = "Back"
|
|
172
|
+
top = "Top"
|
|
173
|
+
bottom = "Bottom"
|
|
174
|
+
|
|
164
175
|
@dataclass
|
|
165
176
|
class Location:
|
|
166
177
|
"""
|
|
@@ -634,22 +645,22 @@ class Entity:
|
|
|
634
645
|
"""
|
|
635
646
|
自分の前方にブロックを設置する。
|
|
636
647
|
"""
|
|
637
|
-
self.client.sendCall(self.uuid, "placeFront")
|
|
638
|
-
return str_to_bool(self.client.result
|
|
648
|
+
self.client.sendCall(self.uuid, "placeFront", [side])
|
|
649
|
+
return str_to_bool(self.client.result)
|
|
639
650
|
|
|
640
651
|
def placeUp(self, side=None) -> bool :
|
|
641
652
|
"""
|
|
642
653
|
自分の真上にブロックを設置する。
|
|
643
654
|
"""
|
|
644
|
-
self.client.sendCall(self.uuid, "placeUp")
|
|
645
|
-
return str_to_bool(self.client.result
|
|
655
|
+
self.client.sendCall(self.uuid, "placeUp", [side])
|
|
656
|
+
return str_to_bool(self.client.result)
|
|
646
657
|
|
|
647
658
|
def placeDown(self, side=None) -> bool :
|
|
648
659
|
"""
|
|
649
660
|
自分の真下にブロックを設置する。
|
|
650
661
|
"""
|
|
651
|
-
self.client.sendCall(self.uuid, "placeDown")
|
|
652
|
-
return str_to_bool(self.client.result
|
|
662
|
+
self.client.sendCall(self.uuid, "placeDown", [side])
|
|
663
|
+
return str_to_bool(self.client.result)
|
|
653
664
|
|
|
654
665
|
def useItemX(self, cord: Coordinates, x: int, y: int, z: int) -> bool :
|
|
655
666
|
"""
|
|
@@ -937,6 +948,34 @@ class Entity:
|
|
|
937
948
|
self.client.sendCall(self.uuid, "isBlockedDown")
|
|
938
949
|
return str_to_bool(self.client.result)
|
|
939
950
|
|
|
951
|
+
|
|
952
|
+
def canDig(self) -> bool :
|
|
953
|
+
"""
|
|
954
|
+
自分の前方のブロックが壊せるかどうか調べる。
|
|
955
|
+
Returns:
|
|
956
|
+
bool: 調べた結果。
|
|
957
|
+
"""
|
|
958
|
+
self.client.sendCall(self.uuid, "isCanDigFront")
|
|
959
|
+
return str_to_bool(self.client.result)
|
|
960
|
+
|
|
961
|
+
def canDigUp(self) -> bool :
|
|
962
|
+
"""
|
|
963
|
+
自分の上のブロックが壊せるかどうか調べる。
|
|
964
|
+
Returns:
|
|
965
|
+
bool: 調べた結果。
|
|
966
|
+
"""
|
|
967
|
+
self.client.sendCall(self.uuid, "isCanDigUp")
|
|
968
|
+
return str_to_bool(self.client.result)
|
|
969
|
+
|
|
970
|
+
def canDigDown(self) -> bool :
|
|
971
|
+
"""
|
|
972
|
+
自分の下のブロックが壊せるかどうか調べる。
|
|
973
|
+
Returns:
|
|
974
|
+
bool: 調べた結果。
|
|
975
|
+
"""
|
|
976
|
+
self.client.sendCall(self.uuid, "isCanDigDown")
|
|
977
|
+
return str_to_bool(self.client.result)
|
|
978
|
+
|
|
940
979
|
def lookAtTarget(self, uuid) -> bool:
|
|
941
980
|
"""
|
|
942
981
|
指定されたエンティティを見る。
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|