• 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!

Prosze o pomysły !

D. Kielb

/home
Joined
Jan 12, 2010
Messages
387
Reaction score
5
Location
nisko
Hihio !

Wrzucajcie tu pomysły na skrypty lua :] postaram się coś zrobić :peace: Mowie nie jestem super koxem lua!
 
Last edited:
Naprowadzanie questow ^^ Czyli daje wspolrzedne, a ty mnie jakos naprowadzasz :D Dam ci repka jak napiszesz.
 
Real Tibia tasks ;] Piotrek się podjął ale nie kończy ;]
Elemental spheres quest? Jak dobrze pamiętam.
Czekam na twoje postaranie sie
 
Pomysł: klikasz 'use' na item o danym ID, po kliknięciu wyświetlana jest informacja:
You have killed XXX/1000 demons.
jeśli zabijesz wszystkie 1k demonów i dasz use na ten item dostajesz nagrode - 1k expa + 1cc, a item znika.
czynność można powtarzać wielokrotnie, pod warunkiem, ze mamy wiecej tego typu itemow.

napiszesz?
 
@Paxton:

/data/talkactions/talkactions.xml
Code:
<talkaction words="!gps" event="script" value="gps.lua"/>

/data/talkactions/scripts/gps.lua
Code:
function onSay(cid, words, param, channel)
	if(channel == CHANNEL_DEFAULT) then
		local tmpParam = string.explode(param, ",")
		if(#tmpParam == 3) then
			for i = 1, 3 do
				doCreatureSetStorage(cid, 12000 + i, tmpParam[i])
			end
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "[GPS] Done.")
		else
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "[GPS] Usage !gps x, y, z")
		end
	end
	return true
end

/data/creaturescripts/scripts/login.lua
Code:
registerCreatureEvent(cid, "gps")

/data/creaturescripts/creaturescripts.xml
Code:
<event type="think" name="gps" event="script" value="gps.lua"/>

/data/creaturescripts/scripts/gps.lua
Code:
local dirs = {
	[NORTH] = "UP",
	[EAST] = "RIGHT",
	[SOUTH] = "DOWN",
	[WEST] = "LEFT",
	[SOUTHWEST] = "<V",
	[SOUTHEAST] = "V>",
	[NORTHWEST] = "<^",
	[NORTHEAST] = "^>"
}

function onThink(cid, interval)
	for i = 1, 3 do
		if(getCreatureStorage(cid, 12000 + i) < 1) then
			return true
		end
	end

	local selfPos = getCreaturePosition(cid)
	doSendAnimatedText(selfPos, dirs[getDirectionTo(selfPos, {x = getCreatureStorage(cid, 12001), y = getCreatureStorage(cid, 12002), z = getCreatureStorage(cid, 12003)})], TEXTCOLOR_WHITE)
	return true
end

Powinno dzialac ^_^
 
Last edited:
@Paxton:

/data/talkactions/talkactions.xml
Code:
<talkaction words="!gps" event="script" value="gps.lua"/>

/data/talkactions/scripts/gps.lua
Code:
function onSay(cid, words, param, channel)
	if(channel == CHANNEL_DEFAULT) then
		local tmpParam = string.explode(param, ",")
		if(#tmpParam == 3) then
			for i = 1, 3 do
				doCreatureSetStorage(cid, 12000 + i, tmpParam[i])
			end
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "[GPS] Done.")
		else
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "[GPS] Usage !gps x, y, z")
		end
	end
	return true
end

/data/creaturescripts/scripts/login.lua
Code:
registerCreatureEvent(cid, "gps")

/data/creaturescripts/creaturescripts.xml
Code:
<event type="think" name="gps" event="script" value="gps.lua"/>

/data/creaturescripts/scripts/gps.lua
Code:
local dirs = {
	[NORTH] = "UP",
	[EAST] = "RIGHT",
	[SOUTH] = "DOWN",
	[WEST] = "LEFT",
	[SOUTHWEST] = "<V",
	[SOUTHEAST] = "V>",
	[NORTHWEST] = "<^",
	[NORTHEAST] = "^>"
}

function onThink(cid, interval)
	for i = 1, 3 do
		if(getCreatureStorage(cid, 12000 + i) < 1) then
			return true
		end
	end

	local selfPos = getCreaturePosition(cid)
	doSendAnimatedText(selfPos, dirs[getDirectionTo(selfPos, {x = getCreatureStorage(cid, 12001), y = getCreatureStorage(cid, 12002), z = getCreatureStorage(cid, 12003)})], TEXTCOLOR_WHITE)
	return true
end

Powinno dzialac ^_^

Ok Smiga :) Dzieki reszte sie dogadamy na gg, dam repka jak moge :D
 
Pomyśle :p a twoj skrypt juz testuje i zaraz Ci go podam :] :peace:

a co tutaj jest do testowania? :O

Code:
function onKill(cid, target)
    local killCount = getPlayerStorageValue(cid, 6512)
    if(killCount > 999)then return true end

    setPlayerStorageValue(cid, 6512, killCount + 1)
    return true
end

function onUse(cid, item)
    local killCount = getPlayerStorageValue(cid, 6512)
    if(killCount < 1000)then
        doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Jestes nob!")
        return true
    end

    doPlayerAddExp(cid, 1000)
    doPlayerAddItem(cid, 2160, 1)
    doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "gz")
    setPlayerStorageValue(cid, 6512, 0)
    return true
end

jak cos pominalem to sorks, pisalem w tym malym boxie ;[
 
Back
Top