Skrypty & Kody Skrypt Na Transform 8.54 POMOC

Odp: Skrypt Na Transform 8.54 POMOC

a jak doda? kolejny transform do
Kod:
function onCastSpell(cid, var)

if getPlayerVocation(cid) == 1 then
if getPlayerLevel(cid) >= 30 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,2)
     doCreatureChangeOutfit(cid, {lookType=7})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end

end
end
Bo tu tu bez tablicy jest.
 
Odp: Skrypt Na Transform 8.54 POMOC

@Up

Kod:
function onCastSpell(cid, var)

if getPlayerVocation(cid) == 1 then
if getPlayerLevel(cid) >= 30 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,2)
     doCreatureChangeOutfit(cid, {lookType=7})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end

elseif getPlayerVocation(cid) == 2 then
if getPlayerLevel(cid) >= 50 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,3)
     doCreatureChangeOutfit(cid, {lookType=8})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end

end
end

Po ka?dym:

Kod:
end
return true
end

dodajesz:

Kod:
elseif getPlayerVocation(cid) == 260 then
if getPlayerLevel(cid) >= 150 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,261)
     doCreatureChangeOutfit(cid, {lookType=435})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end
 
Odp: Skrypt Na Transform 8.54 POMOC

Kod:
elseif getPlayerVocation(cid) == 2 then

I reszt? jedziesz normalnie


P.S. Gram zielas na twoim otku xd nick Tweak :D
 
Odp: Skrypt Na Transform 8.54 POMOC

Ciesze si? :) Ale jak mo?esz to nie wprowadzaj w b??d treex'a , napisa?em jak to ma wygl?da? pod jego postem.
 
Odp: Skrypt Na Transform 8.54 POMOC

Dzi?ki Zielas ^^
 
Odp: Skrypt Na Transform 8.54 POMOC

@Zielas92
Tak! Dzia?a, ?e po wylogowaniu wraca do normal transa :D, posiadasz mo?e skrypt na transform, ale z tablic?? :)
 
Odp: Skrypt Na Transform 8.54 POMOC

@Up
w konsoli pokazuje mi si? b??d, ?e nie ma takiego skryptu "doCreatureChangeOutfit" :(
Ps. Wiesz jak doda? ?eby po ka?dym jednym spellu gracz mia? wi?kszy atak ze spell'a, szybszy atak i mocniejszy z axe, sword itp? Trzeba do w vocations.xml ustawi? czy mo?na doda? do do transform.lua ?
 
Odp: Skrypt Na Transform 8.54 POMOC

S?uchaj testuje skrypt ten co da?e? w linku i wiesz mo?e pod czym to doda??
Kod:
function onLogin(cid) 
if (getPlayerVocation(cid) == 2) then  
        doCreatureAddHealth(cid, getCreatureMaxHealth(cid)) 
        doPlayerAddMana(cid, getPlayerMaxMana(cid)) 
        doPlayerSetVocation(cid, 1)  
        setCreatureMaxHealth(cid, getCreatureMaxHealth(cid) - 300) 
        setCreatureMaxMana(cid, getPlayerMaxMana(cid) - 300)
 
Odp: Skrypt Na Transform 8.54 POMOC

W vocations lepiej ustawi?, ?e przy zmianie voca dodaje bonusy.

tam powinno by? onLogout, tworzysz nowy plik, rejestrujesz go w login i dodajesz do creaturescript
 
Ostatnia edycja:
Odp: Skrypt Na Transform 8.54 POMOC

Je?li chodzi o dmg ze spelli to vocations.xml.

Przyk?ad:

Kod:
<formula meleeDamage="15.0" distDamage="15.0" wandDamage="5.0" magDamage="6.5" magHealingDamage="16.0"

W kolejnym transie dajesz wi?ksze warto?ci, np: magDamage="6.5" na magDamage="7.5"

Co do skilli to wydaje mi si? ?e trzeba jednak edytowa? skrypt na transform. Hmm, mo?e:

Kod:
doPlayerAddSkillTry(cid,2,3)

W miejsce 2 dajesz numer, kt?rego skilla ma dodawa?, znalaz?em gdzie? tak? ma?? ?ci?g?:

0:Fist
1:Club
2:Sword
3:Axe
4: Distance
5:Shield
6:Fishing

W miejsce 3 wpisujesz ile skilla ma dodawa? lub mo?esz spr?bowa? tego:

Kod:
doPlayerAddSkill(cid, SKILL__SWORD, ilo??)

Pozdrawiam.
 
Ostatnia edycja:
Odp: Skrypt Na Transform 8.54 POMOC

Ej bo jak zmieni? voc na ten sam to mi nie dzia?a 2 transform;/
Kod:
function onCastSpell(cid, var)

if getPlayerVocation(cid) == 1 then
if getPlayerLevel(cid) >= 40 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,1)
     doCreatureChangeOutfit(cid, {lookType=183})
     doSendMagicEffect(getCreaturePosition(cid), 13)
exhaustion.set(cid,61260,0)
else

end
return true
end

elseif getPlayerVocation(cid) == 1 then
if getPlayerLevel(cid) >= 80 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,399)
     doCreatureChangeOutfit(cid, {lookType=184})
     doSendMagicEffect(getCreaturePosition(cid), 13)
exhaustion.set(cid,61260,0)
else

end
return true
end

end
end
 
Odp: Skrypt Na Transform 8.54 POMOC

Musisz robi? to w ten spos?b:

Kod:
function onCastSpell(cid, var)

if getPlayerVocation(cid) == 1 then -- pierwszy transform
if getPlayerLevel(cid) >= 40 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,2) -- Zmienia w vocation o numerze 2
     doCreatureChangeOutfit(cid, {lookType=183}) -- Looktype, czyli wygl?d mozesz go spisa? z dat editora
     doSendMagicEffect(getCreaturePosition(cid), 13)
exhaustion.set(cid,61260,0)
else

end
return true
end

elseif getPlayerVocation(cid) == 2 then -- jesli dla tej samej profesji ale kolejny trans to wpisujesz 2
if getPlayerLevel(cid) >= 80 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,3) -- Zmienia w 3 
     doCreatureChangeOutfit(cid, {lookType=184}) 
     doSendMagicEffect(getCreaturePosition(cid), 13)
exhaustion.set(cid,61260,0)
else

end
return true
end

end
end

Nie wiem jak ci to wyt?umaczy? ?eby? zrozumia?, nic trudnego wystarczy pomy?le?. je?eli 1 trans tak jak pokaza?em zmienia z voc id numer 1 na numer 2 to kolejny trans dla tej postaci musi byc z numeru 2 na numer 3, ?apiesz? :D
 
Odp: Skrypt Na Transform 8.54 POMOC

@EDIT
Okej, ogarn??em ju? sam jak doda? si??, atak i mocniejszy spell :D, ale teraz mam problem w tym, ?e nie wiem jak doda? w tym samym pliku transform.lua nowe transforms dla innej postaci ;/
 
Ostatnia edycja:
Odp: Skrypt Na Transform 8.54 POMOC

Opisa?em w poprzednich dw?ch postach jak doda? kolejny transform..

@Up

Kod:
function onCastSpell(cid, var)

if getPlayerVocation(cid) == 1 then
if getPlayerLevel(cid) >= 30 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,2)
     doCreatureChangeOutfit(cid, {lookType=7})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end

elseif getPlayerVocation(cid) == 2 then
if getPlayerLevel(cid) >= 50 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,3)
     doCreatureChangeOutfit(cid, {lookType=8})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end

end
end

Po ka?dym:

Kod:
end
return true
end

dodajesz:

Kod:
elseif getPlayerVocation(cid) == 260 then
if getPlayerLevel(cid) >= 150 then
if exhaustion.get(cid,61260) == false then
doPlayerSetVocation(cid,261)
     doCreatureChangeOutfit(cid, {lookType=435})
     doSendMagicEffect(getCreaturePosition(cid), 12)
exhaustion.set(cid,61260,0)
else

end
return true
end
 
Odp: Skrypt Na Transform 8.54 POMOC

"Dla nowej postaci", jak robi? transforms dla jednej i tej samej postaci to wszystko ekstra ?miga, a jak pr?buj? doda? ju? transforms DLA INNEJ POSTACI to wyskakuje mi b??d, ?e nie znalaz?o zako?czenia "end", a to g?wna prawda ;/
 
Odp: Skrypt Na Transform 8.54 POMOC

Dobra to poka? mi tw?j skrypt na transform ju? z kodem dla nowej profesji, tym kt?ry powoduje b??d w konsoli. Poprawimy :p
 
Odp: Skrypt Na Transform 8.54 POMOC

@FoRent
TAK! Dzi?kuj? Ci, jestes moim nowym mistrzem, ten skrypt z tablic? dzia?a bez problemu, dzi?kuje Ci!
@Edit, FoRent
Mia?by? taki sam skrypt z tablic?, ale na revert? :)
@EDIT2
Temat do zamkni?cia, sam Sobie poradzi?em ;). Zapraszam do tematu "mr 15%, uh 15% Cityguard"
 
Ostatnia edycja:
Back
Do góry