Skrypty & Kody Skrypt Npc i potworek

Zapalniczka

Active User
Zarejestrowany
Dołączył
Luty 2, 2015
Posty
132
Liczba reakcji
2
Biore misje u Npc, np: mam do zabicia 1 boss dragona i zabijam go i nie zalicza dla mnie misji u npc

---------- Tre?? dodana o 12:04 ----------

elseif(msgcontains(msg, 'dragon')) then
if (getPlayerStorageValue(cid,56435) == 1) then
selfSay('Find the {Boss Dragon} and kill him!', cid)
else
 
Odp: Skrypt Npc i potworek

Jaki? dodatkowy skrypt w creaturescripts, kt?ry zmienia Ci storage po zabiciu masz?
Dobrze by?oby te? pozna? ca?y kod skryptu a nie urywek.
 
Odp: Skrypt Npc i potworek

Caretures


function onKill(cid, target)
local name = getCreatureName(target)
local storage = getPlayerStorageValue(cid,56435)

if(isMonster(target) == TRUE) then

if storage == 0 then
if name == "Dragon Boss" then
doPlayerSay(cid, 'misja zaliczona!', TALKTYPE_ORANGE_1)
setPlayerStorageValue(cid, 56435, 1)

end
end
end
return true
end

---------- Tre?? dodana o 13:04 ----------

elseif(msgcontains(msg, 'dragon')) then
if (getPlayerStorageValue(cid,56435) == 1) then
selfSay('Find the {Boss Dragon} and kill him!', cid)
else
selfSay('Are you sure want to ride on Dragon?', cid)
talkState[talkUser] = 4
end

elseif(msgcontains(msg, 'yes') and talkState[talkUser] == 4) then
if getPlayerLevel(cid) >= 800 then
if (getPlayerStorageValue(cid,75126) ~= 1) then
selfSay('Not done mission. Say {mission}', cid)
talkState[talkUser] = 8
else
if(getGlobalStorageValue(56126) ~= 1) then

for x = cleandragon.from.x, cleandragon.to.x do
for y = cleandragon.from.y, cleandragon.to.y do
for z = cleandragon.from.z, cleandragon.to.z do
areapos = {x = x, y = y, z = z, stackpos = 253}
getMonsters = getThingfromPos(areapos)
if isMonster(getMonsters.uid) then
doRemoveCreature(getMonsters.uid)
end
end
end
end

doTeleportThing(cid, dragon)
doCreateMonster("Dragon Special", dragonmonster)
setGlobalStorageValue(56126, 1)
else
selfSay('The room is busy, you must wait!', cid)
end
end
else
selfSay('You dont have 800 lvl!', cid)
end
 
Odp: Skrypt Npc i potworek

Zamie?
[lua]elseif(msgcontains(msg, 'dragon')) then
if (getPlayerStorageValue(cid,56435) == 1) then
selfSay('Find the {Boss Dragon} and kill him!', cid)[/lua]


[lua]elseif(msgcontains(msg, 'dragon')) then
if (getPlayerStorageValue(cid,56435) ~= 1) then
setPlayerStorageValue(cid, 56435, 0)
selfSay('Find the {Boss Dragon} and kill him!', cid)[/lua]
 
Odp: Skrypt Npc i potworek

dalej nie dziala
14:00 Rider Master: Find the Dragon Boss and kill him!
14:00 Son Goku [1851]: yes
14:00 Rider Master: Not done mission. Say mission

a zabijam bossa

---------- Tre?? dodana o 14:04 ----------

nie znajduje creatures tak moim zdaniem
 
Odp: Skrypt Npc i potworek

[lua]function onKill(cid, target)
if isPlayer(target) or getCreatureMaster(target) or isNpc(target) then
return true
else
local name = "dragon boss"
local storage = 56435
if getPlayerStorageValue(cid,storage) == 0 then
if name:lower() == getCreatureName(target):lower() then
doPlayerSay(cid, 'misja zaliczona!', TALKTYPE_ORANGE_1)
setPlayerStorageValue(cid, storage, 1)
end
end
end
return true
end[/lua]
 
Ostatnia edycja:
Back
Do góry