What's new

Potrafi? by kto? przerobi? ten skrypt albo zna inny lepszy ?

Status
Not open for further replies.

Dyzajasz

Active User
Joined
Sep 13, 2008
Messages
134
Reaction score
7
Chodzi g??wnie o to ?eby kto? dostawa?a item za zabicie gracza a nie ?e 15 os?b leje kogo? i 15 os?b dostaje item tylko ta osoba co zabi?a.

Skrypt :
function onKill(cid, target, lastHit)
local id = 5944
local id2 = 1990
if isPlayer(cid, lastHit) == true and isPlayer(target, lastHit) == true then
doPlayerAddItem(cid,id,1)
doPlayerAddItem(cid,id2,1)
end
return true
end

Z g?ry dzi?kuj? za pomoc !
 

Dyzajasz

Active User
Joined
Sep 13, 2008
Messages
134
Reaction score
7
Odp: Potrafi? by kto? przerobi? ten skrypt albo zna inny lepszy ?

Refresh
 

Dubler

Lua Factory =)
Joined
Apr 8, 2009
Messages
1,874
Reaction score
112
Odp: Potrafi? by kto? przerobi? ten skrypt albo zna inny lepszy ?

w creature scripts onkill zrob skrypt to wtedy killer dostanie a nie wszyscy...
@edit:
a nie doczytalem, tu juz jest onkill...
w ka?dym razie po necie kr??y tzw. system puchark?w, z niego sobie wyedytuj odpowiedni kod
 

keal1

Advanced User
Joined
Dec 8, 2009
Messages
339
Reaction score
21
Odp: Potrafi? by kto? przerobi? ten skrypt albo zna inny lepszy ?

To bardzo proste
PHP:
local item = 2160 
function onKill(cid, target, lastHit) 
    if isPlayer(cid) == true and isPlayer(target) == true and lastHit then 
        doPlayerAddItem(cid, item, 1) 
    end 
return true 
end

Dodana funkcja lastHit = true wi?c teraz dostane tylko osoba kt?ra ostatnio dobije
 

Dyzajasz

Active User
Joined
Sep 13, 2008
Messages
134
Reaction score
7
Odp: Potrafi? by kto? przerobi? ten skrypt albo zna inny lepszy ?

Dalej dostaj? inne postacie te itemy ;/
 
Last edited:
Status
Not open for further replies.
Top