|
İçerde : 1 misafir, 0 üye : ---
|
src.newitem i....,1,<src>
if <isuncountable ...>
new.dupe <dargs>
else
amount <dargs>
endif
new.update
if (<isuncountable <serv.itemdef.<dlocal._for>,<def.<src.ctag.buy>>>.baseid>>)
Can't resolve <isuncountable i_club>
Undefined symbol
on=0 2
if (<argn> == 1)
for 1 <f_moonsep 0,<def.<src.ctag.buy>>>
if !strmatch(*"*,<argtxt[<eval <local._for>>]>>) && (<isvcheck <argtxt[<eval <local._for>>]>>)
if (<isuncountable <serv.itemdef.<f_moonsep <dlocal._for>,<def.<src.ctag.buy>>>.baseid>>)
serv.newitem <serv.itemdef.<f_moonsep <dlocal._for>,<def.<src.ctag.buy>>>.baseid>
new.cont <src.findlayer.21>
new.dupe <eval <argtxt[<eval <local._for>>]>-1>
else
serv.newitem <serv.itemdef.<f_moonsep <dlocal._for>,<def.<src.ctag.buy>>>.baseid>,<argtxt[<eval <local._for>>]>
new.cont <src.findlayer.21>
endif
//new.amount <argtxt[<eval <local._for>>]>
//hata <serv.itemdef.<f_moonsep <dlocal._for>,<def.<src.ctag.buy>>>.name> <argtxt[<eval <local._for>>]>
endfor
endif
endif
[Defname hamit]
uncountable_types=-t_potion-t_weapon_sword-t_weapon_fence-
[Function isuncountable]
LOCAL.ITYPE=<serv.item.<args>.type>
if (STRMATCH('*-<LOCAL.ITYPE>-*', '<def.uncountable_types>'))
return 1
endif
return 0
[Dialog d_... BUTTON]
On=1919412414
src.newitem i_katana,1,<src>
if <isuncountable i_katana>
new.dupe <dargtxt[0]> //1,2,3,4 artık argtxt'in idsi kaç ise.
else
new.amount <dargtxt[0]>
endif
new.update
src.update
if <isuncountable i_katana>
Can't resolve <isuncountable i_katana>
[function newitem_x]
local.item = <argv[0]>
local.sayi = <argv[1]>
if !(<dlocal.sayi> == 0) && (<dlocal.sayi> == 1)
serv.newitem <local.item>
new.bounce
else
for 1 <dlocal.sayi>
serv.newitem <local.item>
new.bounce
endfor
endif
xwerswoodx :
Ben for döngüsünü pek sevmiyorum bu tarzda neden dersen çok fazla item olduğu zaman kasıyor sunucuyu
@Disayner
Önce function'ı yazman gerekiyor. Yukarda yazılı bir örneğini verdim
Mortal :
xwerswoodx :
Ben for döngüsünü pek sevmiyorum bu tarzda neden dersen çok fazla item olduğu zaman kasıyor sunucuyu
@Disayner
Önce function'ı yazman gerekiyor. Yukarda yazılı bir örneğini verdim
Haklısın senin kullandığın dupe örneği gayet yerinde bir örnek olmuş.Onunla değişebilirmiş =)
[FUNCTION newgold2]
IF (<ARGS> > 0)
serv.newitem i_gold
IF (<ARGS> > 65000)
new.amount=65000
new.bounce
newgold2 <eval <ARGS>-<NEW.AMOUNT>>
ELSE
new.amount=<ARGS>
new.bounce
ENDIF
ENDIF
[function isstackable]
serv.newitem <args>
ref1 = <new>
if (<ref1.can>&CAN_I_PILE) > 0
return 1
else
return 0
endif
new.remove
|