• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

addon z chesta

Daxu

Banned User
Joined
Jun 18, 2010
Messages
336
Reaction score
9
Location
Poland
kurna jakos zrobilem koslawy script bo chce takie cos ze dodaje 2 addony do wayfarer outfit jak sie na skrzynke uzyje i mam wlasnie ten skrypt:
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
        if item.itemid == 1746 then
            local pPos = getPlayerPosition(cid)
            doSendMagicEffect(pPos, 28)
                doPlayerAddOutfit(cid,366,2)
                doPlayerAddOutfit(cid,366,2)
                doPlayerAddOutfit(cid,367,2)
                doPlayerAddOutfit(cid,367,2)
                    doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Dostales Addon!.")
        end
        return TRUE
end
ale on daje tylko second addon i caly czas dodaje nie ma blokady moglby ktos pokazac jak to przerobic i funkcje :p
 
kurna jakos zrobilem koslawy script bo chce takie cos ze dodaje 2 addony do wayfarer outfit jak sie na skrzynke uzyje i mam wlasnie ten skrypt:
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
        if item.itemid == 1746 then
            local pPos = getPlayerPosition(cid)
            doSendMagicEffect(pPos, 28)
                doPlayerAddOutfit(cid,366,2)
                doPlayerAddOutfit(cid,366,2)
                doPlayerAddOutfit(cid,367,2)
                doPlayerAddOutfit(cid,367,2)
                    doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Dostales Addon!.")
        end
        return TRUE
end
ale on daje tylko second addon i caly czas dodaje nie ma blokady moglby ktos pokazac jak to przerobic i funkcje :p


Ja sobie napisałem na wszystkie questy w 1 skrypcie, oczywiście nie z 1 skrzynki. Jak chcesz to PW.
 
Buziaki się należą:
outfity = {
[0] = {outfitmale = 128, outfitfemale = 136, addon = 1, nazwamale = "citizen", nazwafemale = "citizen", uniqueid = 11000},
[1] = {outfitmale = 128, outfitfemale = 136, addon = 2, nazwamale = "citizen", nazwafemale = "citizen", uniqueid = 11001},
[2] = {outfitmale = 129, outfitfemale = 137, addon = 1, nazwamale = "hunter", nazwafemale = "hunter", uniqueid = 11002},
[3] = {outfitmale = 129, outfitfemale = 137, addon = 2, nazwamale = "hunter", nazwafemale = "hunter", uniqueid = 11003}
i tak dalej...


}
function onUse(cid, item, fromPos, itemEx, toPos)
for i = 0, #outfity do
if item.uid == outfity.uniqueid then
if getPlayerStorageValue(cid, outfity.uniqueid) < 1 then
if getPlayerSex(cid) == 1 then
doPlayerAddOutfit(cid, outfity.outfitmale, outfity.addon)
doCreatureSay(cid, 'Zdobyles addon numer ' .. outfity.addon .. ' do ' .. outfity.nazwamale .. ' outfit.', TALKTYPE_MONSTER)
doPlayerSetStorageValue(cid, outfity.uniqueid, 1)
else
doPlayerAddOutfit(cid, outfity.outfitfemale, outfity.addon)
doCreatureSay(cid, 'Zdobylas addon numer ' .. outfity.addon .. ' do ' .. outfity.nazwafemale .. ' outfit.', TALKTYPE_MONSTER)
doPlayerSetStorageValue(cid, outfity.uniqueid, 1)
end
else
doCreatureSay(cid, 'Posiadasz juz ' .. outfity.addon .. ' addon do ' .. outfity.nazwamale .. ' outfit.', TALKTYPE_MONSTER)
end
else
-- ERROR --
end

end

return true
end
 
Texon brzydko i weak avatar
Samme goood
tylko moge klikac caly czas i mi dodaje addon ;D
 
Texon brzydko i weak avatar
Samme goood
tylko moge klikac caly czas i mi dodaje addon ;D

No to dodaj sobie storage.

PHP:
function onUse(cid, item, fromPosition, itemEx, toPosition)

local storage = 999999

if getPlayerStorageValue(cid, storage) == -1 then
        if item.itemid == 1746 then
            local pPos = getPlayerPosition(cid)
            doSendMagicEffect(pPos, 28)
            doPlayerAddOutfit(cid, 366, 3)
            setPlayerStorageValue(cid, storage, 1)

                    doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Dostales Addon!.")
else
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Juz brales =D.")

end
        end
        return TRUE
end
 
jak klikam to nie pisze juz masz nic nie ma 0 reakcji i 0 bledow
 
Rozkmiń scrypt, klikasz na "statuetke"(możesz zmienić na check) i daje ci addon.

Code:
function onUse(cid, item, frompos, item2, topos)

if item.uid ==5071 then
queststatus = getPlayerStorageValue(cid,5071)
if queststatus == 1 then
doPlayerSendTextMessage(cid,22,"This quest is empty.")

else
doPlayerSendTextMessage(cid,22,"You found a assassin addon.")
doSendMagicEffect(topos,12)
if getPlayerSex(cid) == 0 then
doPlayerAddOutfit(cid, 156, 1)
doPlayerAddOutfit(cid, 152, 1)
setPlayerStorageValue(cid,8007,2)
else
doPlayerAddOutfit(cid, 156, 1)
doPlayerAddOutfit(cid, 152, 1)
talk_state = 1
end
end
return 0
end
return 1
end
 
Code:
local addons =
{
	[1000] =
	{
		outfitId = 1,
		storage = 10000,
		str = "citizen"
	},
	[1001] =
	{
		outfitId = 2,
		storage = 10001,
		str = "hunter"
	}
}

function onUse(cid, item, fromPosition, itemEx, toPosition)
	local addon = addons[item.uid]
	if(not addon) then
		return true
	end
	
	local storage = getCreatureStorage(cid, addon.storage)
	if(storage > 0) then
		doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Posiadasz juz addony do outfitu " .. addon.str .. "!")
		return true
	end
	
	doPlayerAddOutfitId(cid, addon.outfitId, 3)
	doCreatureSetStorage(cid, addon.storage, 1)
	doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Otrzymales wszystkie addony do outfitu " .. addon.str .. "!")
	return true
end
 
o czekaj jak ja mam to uzupelnic jak chce wayfarer

[1000] =
{
outfitId = 1,
storage = 10000,
str = "citizen"
},
[1001] =
{
outfitId = 2,
storage = 10001,
str = "hunter"
}
 
Back
Top