- UID
- 58000
- 帖子
- 49
- 主題
- 3
- 精華
- 0
- 積分
- 87
- 威望
- 5
- 金錢
- 52
- 貢獻
- 0
- 閱讀權限
- 10
- 在線時間
- 19 小時
- 註冊時間
- 2016-7-8
- 最後登錄
- 2017-8-23
|
請問有像這樣的指令嗎
請問有人知道怎麼編寫
或者可以分享類似的指令嗎
想查詢怪物的掉落同時知道他出再哪一張地圖
----------------------
這是查全怪掉落的代碼
從MYSQL查詢功能使用
Select d.mobId,n.name As mobname,n.gfxid As mobgfxid,n.lvl As moblvl,d.itemId,e.invgfx As iteminvgfx,e.name As itemname,d.min,d.max,d.chance From droplist d left join (Select item_id,name,invgfx From (Select item_id,name,invgfx From armor UNION ALL Select item_id,name,invgfx From etcitem UNION ALL Select item_id,name,invgfx From weapon) t) e On d.itemId=e.item_id left join npc n On n.npcid=d.mobId;
---------------------------------
------------------------------
怪物編號查詢掉落物品.sql
SELECT
npc.name AS `怪物名稱`,
droplist.mobId AS `怪物編號`,
droplist.itemId AS `道具編號`,
weapon.name AS `武器名稱`,
armor.name AS `防具名稱`,
etcitem.name AS `道具名稱`,
droplist.chance AS `掉落機率`
FROM
droplist
Inner Join npc ON droplist.mobId = npc.npcid
Left Join weapon ON droplist.itemId = weapon.item_id
Left Join armor ON droplist.itemId = armor.item_id
Left Join etcitem ON droplist.itemId = etcitem.item_id
WHERE
droplist.mobId = '45601'
(不要複製此行 最後一行該怪物的號碼)
--------------------------------------------------------------
地圖編號查詢怪物分布
SELECT
`npc`.`name` AS `怪物名稱`,
`npc`.`npcid` AS `怪物編號`,
`spawnlist`.`count` AS `隻數`,
`spawnlist`.`min_respawn_delay` AS `最小重生`,
`spawnlist`.`max_respawn_delay` AS `最大重生`,
`mapids`.`locationname` AS `地圖名稱`,
`mapids`.`mapid` AS `地圖編號`
FROM
`spawnlist`
Inner Join `npc` ON `spawnlist`.`npc_templateid` = `npc`.`npcid`
Inner Join `mapids` ON `spawnlist`.`mapid` = `mapids`.`mapid`
WHERE
`spawnlist`.`mapid` = '180'
-------------------------------------------------------------- |
|