若是你卡在這里了,那么看看這個攻略吧
選擇英雄和編程說話
選擇裝備
寫中文注釋
寫代碼
# Don't insult this tribe of peaceful ogres.
while True:
item = hero.findNearestItem()
if item:
# If item.type IS NOT EQUAL TO "gem"
if item.type != "gem":
# 然后跟從你的寵物。
hero.moveXY(pet.pos.x, pet.pos.y)
# 不然:
else:
# 移動到寶石的坐標。
hero.moveXY(item.pos.x, item.pos.y)
運行
寫代碼
// 不要欺侮這個和平食人魔部落
while(true) {
var item = hero.findNearestItem();
if(item) {
// 若是item.type不等于 "gem"
if(item.type != "gem") {
// 然后跟從你的寵物。
hero.moveXY(pet.pos.x, pet.pos.y);
}
// 不然:
else {
// 移動到寶石的坐標。
hero.moveXY(item.pos.x, item.pos.y);
}
}
}
運行
寫代碼
# Don't insult this tribe of peaceful ogres.
while true
item = hero.findNearestItem()
if item
# If item.type IS NOT EQUAL TO "gem"
if item.type != "gem"
# 然后跟從你的寵物。
hero.moveXY(pet.pos.x, pet.pos.y)
# 不然:
else
# 移動到寶石的坐標。
hero.moveXY(item.pos.x, item.pos.y)
運行
寫代碼
-- 不要欺侮這個和平食人魔部落
while true do
local item = hero:findNearestItem()
if item then
-- 若是item.type不等于 "gem"
if item.type ~= "gem" then
-- 然后跟從你的寵物。
hero:moveXY(pet.pos.x, pet.pos.y)
-- 不然:
else
-- 移動到寶石的坐標。
hero:moveXY(item.pos.x, item.pos.y)
end
end
end
運行
0 篇文章
如果覺得我的文章對您有用,請隨意打賞。你的支持將鼓勵我繼續創作!