Licznik zabitych potworów
Strona 1 z 1
Licznik zabitych potworów
Skrypt pochodzi z silnika db hayate. Zlicza on liczbę potworów ,które zabiliśmy
W creaturescript/creaturescript.xml wklepujemy:
W creaturescript/creaturescript.xml wklepujemy:
- Kod:
<event type="kill" name="licznik" event="script" value="licznik.lua"/>
- Kod:
registerCreatureEvent(cid, "licznik")
- Kod:
function onKill(cid, target, lastHit)
if isMonster(target) then
local storage = 20001
for i = 1, getCreatureName(target):len() do
storage = storage + getCreatureName(target):byte(i,i)
end
if getPlayerStorageValue(cid,storage) < 0 then
setPlayerStorageValue(cid,storage,0)
end
setPlayerStorageValue(cid,storage,getPlayerStorageValue(cid,storage) + 1)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "Do tej pory zabiles " .. getCreatureName(target):lower() .. " " .. getPlayerStorageValue(cid,storage) .. " !")
end
return true
end
darkes- Uploader
- Liczba postów : 27
Join date : 13/11/2012
Strona 1 z 1
Permissions in this forum:
Nie możesz odpowiadać w tematach
|
|