Pomocy pytanie kierowane do dobrych skrypterow

Status
Zamknięty.

szakers

Active User
Zarejestrowany
Dołączył
Październik 11, 2009
Posty
101
Liczba reakcji
3
Witam mam taki skrypt
ktory utworzylem w skript w folderze talkations ten skrypt dziala
Kod:
function onSay(cid, param) 
local pos = getPlayerPosition(cid)
  doSummonCreature("Bug",pos)
  doSendMagicEffect(pos,3)
  return true
end
a to do data/talkactions.xml
Kod:
<talkaction words="komenda"  event="script" script="nazwa skryptu.lua" />
ten skrypt dziala ale z prozbal sie zwracam poniewaz chce zeby ten skrypt byl z ograniczeniem do 4 bogow np ale ma byc do czterech
pomocy pilne!!
 
Odp: Pomocy pytanie kierowane do dobrych skrypterow

Tutaj masz przyk?ad Twojej komendy, kt?r? edytowa?em w taki spos?b, aby mo?na by?o u?y? jej tylko 2 razy.
function onSay(cid, param)
if getPlayerStorageValue(cid, 60200) == -1 then

local pos = getPlayerPosition(cid)
doSummonCreature("Bug",pos)
doSendMagicEffect(pos,3)

doPlayerSetStorageValue(cid,60200, 1)



elseif getPlayerStorageValue(cid, 60201) == -1 then
local pos = getPlayerPosition(cid)
doSummonCreature("Bug",pos)
doSendMagicEffect(pos,3)

doPlayerSetStorageValue(cid,60201, 1)

else

doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR, "You have already summoned 2 bugs and can not do it again.")

end
end
end
 
Ostatnia edycja:
Odp: Pomocy pytanie kierowane do dobrych skrypterow

Tutaj masz przyk?ad Twojej komendy, kt?r? edytowa?em w taki spos?b, aby mo?na by?o u?y? jej tylko 2 razy.
Cytat:
Kod:
function onSay(cid, param)
if getPlayerStorageValue(cid, 60200) == -1 then

local pos = getPlayerPosition(cid)
doSummonCreature("Bug",pos)
doSendMagicEffect(pos,3)

doPlayerSetStorageValue(cid,60200, 1)



elseif getPlayerStorageValue(cid, 60201) == -1 then
local pos = getPlayerPosition(cid)
doSummonCreature("Bug",pos)
doSendMagicEffect(pos,3)

doPlayerSetStorageValue(cid,60201, 1)

else

doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR, "You have already summoned 2 bugs and can not do it again.")

end
end
end

przykro mi nie dziala na moim silniku wyskakuje blad
 
Ostatnio edytowane przez moderatora:
Odp: Pomocy pytanie kierowane do dobrych skrypterow

przykro mi nie dziala na moim silniku wyskakuje blad
Podaj prosz? ten b??d, mo?liwe, ?e gdzie? si? pomyli?em, bo nie mam mo?liwo?ci sprawdzenia skryptu "na ?ywo".
 
Odp: Pomocy pytanie kierowane do dobrych skrypterow

prosze to ten blad o ktory prosiles
bykj.png
 
Odp: Pomocy pytanie kierowane do dobrych skrypterow

Spr?buj tego:
function onSay(cid, param)
if getPlayerStorageValue(cid, 60200) == -1 then

local pos = getPlayerPosition(cid)
doSummonCreature("Bug",pos)
doSendMagicEffect(pos,3)

doPlayerSetStorageValue(cid,60200, 1)



elseif getPlayerStorageValue(cid, 60201) == -1 then
local pos = getPlayerPosition(cid)
doSummonCreature("Bug",pos)
doSendMagicEffect(pos,3)

doPlayerSetStorageValue(cid,60201, 1)

else

doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR, "You have already summoned 2 bugs and can not do it again.")

end
end
 
Odp: Pomocy pytanie kierowane do dobrych skrypterow

Lito?ci...
PHP:
function onSay(cid, words, param)
local max_summons, summons, pos = 2, getCreatureSummons(cid), getCreaturePosition(cid)
if(table.maxn(summons) <= max_summons-1) then
  doSummonCreature("Bug",pos)
  doSendMagicEffect(pos,3)
end
  return true
end
 
Ostatnia edycja:
Odp: Pomocy pytanie kierowane do dobrych skrypterow

nie dziala moze to od tego zalezy
w talkations.xml mam
<talkaction words="komenda" event="script" script="komenda.lua" />
 
Status
Zamknięty.
Back
Do góry