#1 2007-01-07 09:27:00

Bartiii

http://i37.tinypic.com/okc0lk.gif

Zarejestrowany: 2007-01-06
Posty: 4

NPC Inwazjer

na poczatek tworzymy w data\npc\ plik Inwazjer
i wpisujemy
Kod

Kod:

<npc name="Inwazjer" script="data/npc/scripts/inwazje.lua" access="3" lookdir="2">
<mana now="800" max="800"/>
<health now="200" max="200"/>
<look type="129" head="0" body="94" legs="94" feet="114"/>
</npc>

i potem w data\npc\scripts tworzymy plik inwazje

i
Kod

Kod:

focus = 0
talk_start = 0
target = 0
following = false
attacking = false

function onThingMove(creature, thing, oldpos, oldstackpos)

end


function onCreatureAppear(creature)

end


function onCreatureDisappear(cid, pos)
if focus == cid then
selfSay('Good bye then.')
focus = 0
talk_start = 0
end
end


function onCreatureTurn(creature)

end

function msgcontains(txt, str)
return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)'))
end


function onCreatureSay(cid, type, msg)
msg = string.lower(msg)

if ((string.find(msg, '(%a*)hi(%a*)')) and (focus == 0)) and getDistanceToCreature(cid) < 4 then
selfSay('Hello ' .. creatureGetName(cid) .. '! Chcesz inwazji ?? kogo ...: Orc,Dwarf,Minotaur,Elf,Human,Dragon,GS,Demon,Orsh,Orshabaal.')
focus = cid
talk_start = os.clock()
end

if msgcontains(msg, 'demon') and focus == cid then
selfSay('/m demon')
talk_start = os.clock()
end

if msgcontains(msg, 'orshabaal') and focus == cid then
selfSay('/m orshabaal')
talk_start = os.clock()
end

if msgcontains(msg, 'dwarf') and focus == cid then
selfSay('/m dwarf')
talk_start = os.clock()
end

if msgcontains(msg, 'orc') and focus == cid then
selfSay('/m inwazja orc')
talk_start = os.clock()
end

if msgcontains(msg, 'orsh') and focus == cid then
selfSay('/m orsh')
talk_start = os.clock()
end


if msgcontains(msg, 'minotaur') and focus == cid then
selfSay('/m minotaur')
talk_start = os.clock()
end

if msgcontains(msg, 'gs') and focus == cid then
selfSay('/m giant spider')
talk_start = os.clock()
end

if msgcontains(msg, 'elf') and focus == cid then
selfSay('/m elf')
talk_start = os.clock()
end

if msgcontains(msg, 'human') and focus == cid then
selfSay('/m human')
talk_start = os.clock()
end

if msgcontains(msg, 'dragon') and focus == cid then
selfSay('/m dragon')
talk_start = os.clock()
end

if string.find(msg, '(%a*)bye(%a*)') and focus == cid and getDistanceToCreature(cid) < 4 then
selfSay('Good bye, ' .. creatureGetName(cid) .. '!')
focus = 0
talk_start = 0
end
end

function onCreatureChangeOutfit(creature)

end

function onThink()
if (os.clock() - talk_start) > 30 then
if focus > 0 then
selfSay('Next Please...')
end
focus = 0
end
if focus ~= 0 then
if getDistanceToCreature(focus) > 5 then
selfSay('Good bye then.')
focus = 0
end
end
end

Myslę ze się przyda jak tamte poprzednie ;]

Offline

 

#2 2007-01-07 12:27:07

Guzur

http://i34.tinypic.com/3321jrs.gif

Zarejestrowany: 2006-04-17
Posty: 1526
WWW

Re: NPC Inwazjer

Ten NPC inwazjer samodzielnie stawia potworki co jaki¶ czas czy jak się do niego napisze? Bo te co się do nich pisze, żeby stawiały potworki s± do kitu bo jaki¶ low lvl przylezie i postawia orsche itp. albo taki high lvl i postawia i ucieknie, a wtedy masa ludzi ginie:P


"Oczywi¶cie, że wiem kim jeste¶... Moj± prac± jest wiedzieć"

"Gdyby byki i konie miały ręce i mogły nimi malować i tworzyć dzieła, jak ludzie, to konie malowały by postacie bogów podobne do koni, i takież ciała im dawały, a byki podobne do byków"

Offline

 

#3 2007-04-10 20:50:10

Danioo

http://i38.tinypic.com/19pb0n.gif

Zarejestrowany: 2007-04-09
Posty: 12

Re: NPC Inwazjer

zgadzam sie z guzurem dla mnie tacy "Inwazjerzy" sa bez sensu jakis hight lvl zrobi 5 demcuw i lov levele beda dedac. do otsuw nie polecam ale do zabawy jest fajny.lepiej expc samodzilnie wieksza fraida P.O.Z.D.R.O

Jestem Guzur nie Gazur xD (nie wiem czego ale często na mnie tak mówi± w Tibii )- Guzur

Ostatnio edytowany przez Guzur (2007-04-10 22:09:02)

Offline

 

#4 2007-07-08 17:27:09

wojtek15

http://i36.tinypic.com/25zpd2c.gif

Zarejestrowany: 2007-07-03
Posty: 349

Re: NPC Inwazjer

NPC bez sensu nie polecam.

Offline

 

#5 2007-07-09 15:48:05

fanatyk_ganji

http://i38.tinypic.com/19pb0n.gif

Zarejestrowany: 2007-05-07
Posty: 10

Re: NPC Inwazjer

Hmmmmm mi sie przyda poniewaz gdy sam tworze potwory to sie laguje!!! A moglby ktos powiedziec co zrobic by te potwory tworzyly sie w odpowiednich miejscach i np. nie po 1 ale po ok 5??

Offline

 

#6 2008-01-03 17:38:06

Pimpek

http://i37.tinypic.com/okc0lk.gif

Zarejestrowany: 2008-01-02
Posty: 5

Re: NPC Inwazjer

Taki NPC może się przydać na arenę
Tam jak ludzie będ± sobie stawiać potworki i jak padn±, to nic im nie wyleci... To może służyć jako trening przed pój¶ciem na hunta

Offline

 

Stopka forum

RSS
Powered by PunBB
© Copyright 2002–2008 PunBB
Polityka cookies - Wersja Lo-Fi


Darmowe Forum | Ciekawe Fora | Darmowe Fora
Betonové Jímky Žirovnice Ubytování Caracas