SphereCommunity
vendor system - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Help (/Forum-Script-Help)
+--- Thread: vendor system (/Thread-vendor-system)



vendor system - Kapa - 10-09-2014 02:07 AM

Hi, can anyone tell me why this script doesnt work? after setting the price item goes to bank box not in to selling list.


RE: vendor system - Kapa - 10-09-2014 03:54 AM

i think the problem is here but not sure exactly what

[DIALOG d_remover_item1 BUTTON]
on=0
findid.i_m_vendorfala.remove

on=1
If (<distance> > 5)
src.sysmessage <def.toofar>
findid.i_m_vendorfala.remove
return 1
endif
if !(0<tag.iuid<eval <tag.current>>>)
src.sysmessage <def.noitens_forsale_inslot>
findid.i_m_vendorfala.remove
return 1
endif
local.lastp=<src.p>
local.flags=<src.region.flags>
src.region.flags=0
src.p=1,1
try tag.preco<eval <tag.current>>
try uid.<tag.iuid<eval <tag.current>>>.cont=<src.findlayer.29>
try uid.<tag.iuid<eval <tag.current>>>.tag.dispid2
try tag.iuid<eval <tag.current>>
try tag.desc<eval <tag.current>>
tag.current -= 1
src.sysmessage <def.itens_banked1>
f_ajeitar_itens
tag.itensavenda -= 1
findid.i_m_vendorfala.remove
src.bankself
src.p=<local.lastp>
src.region.flags=<local.flags>
src.update

[DIALOG d_vendor_owner_pod BUTTON]
on=0
findid.i_m_vendorfala.remove

on=1
If (<distance> > 5)
src.sysmessage <def.toofar>
findid.i_m_vendorfala.remove
return 1
endif
If !(<tag0.itensavenda>)
src.sysmessage <def.noitens_forsale>
sdialog d_vendor_owner_pod
return 1
endif
local.lastp=<src.p>
local.flags=<src.region.flags>
src.region.flags=0
src.p 1,1
serv.newitem=i_backpack
new.name=Vendor Bag
new.color=39
new.cont=<src.findlayer.29>
f_retirar_itens <new>
tag.itensavenda=0
src.sysmessage <def.itens_banked1>
findid.i_m_vendorfala.remove
src.p=<local.lastp>
src.region.flags=<local.flags>
src.update