SphereCommunity
vendor - Printable Version

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



vendor - zevs232 - 01-06-2015 03:00 AM

hello , really no one has that script?
but full script .



[DIALOG d_auction_item_list] //should be called with the bankbox of the auctioneer as default object
0,60
PAGE 0
NOMOVE
button 489 450 24 24 1 0 3 //my items
button 646 4 24 24 1 0 4 //search button
button 22 60 24 24 1 0 5 //platemail
button 22 80 24 24 1 0 6 //ringmail
button 22 100 24 24 1 0 7 //chainmail
button 22 120 24 24 1 0 8 //studded
button 30 140 24 24 1 0 9 //crystal sets
button 30 160 24 24 1 0 20 //crystal sets
button 15 180 24 24 1 0 10 //weapons
button 15 200 24 24 1 0 11 //bows
button 15 220 24 24 1 0 12 //mounts
button 349 450 24 24 1 0 13 // all items
button 419 450 24 24 1 0 14 //sell item
button 559 450 24 24 1 0 15 // cashout
button 15 240 24 24 1 0 16 //bottles
button 15 260 24 24 1 0 17 //imbues
button 13 415 24 24 1 0 18 //misc
button 15 40 24 24 1 0 19 //armors
resizepic 0 0 9300 800 480
resizepic 440 3 3000 200 22
resizepic 645 3 3000 60 22
resizepic 345 442 3000 65 35
resizepic 415 442 3000 65 35
resizepic 485 442 3000 65 35
resizepic 555 442 3000 65 35
resizepic 8 40 3000 253 400 //kreisa puse
resizepic 265 40 3000 528 400 //labaa puse
resizepic 8 26 3000 785 8 //augseja dala
dtext 8 5 6208 Uo Company Walmart
dtext 145 5 014D *
dtext 165 5 0112 - Sorting by latest Added item
dtext 650 40 014D Price (gp)
dtext 625 40 014D *
dtext 380 40 014D Name
dtext 654 3 6208 Search
dtext 300 40 014D Photo
dtext 350 448 014D All items
dtext 420 448 0112 Sell item
dtext 490 448 0225 My items
dtext 563 448 2015 Cashout
dtext 15 40 0112 Armors
dtext 25 60 6208 Platemail
dtext 25 80 6208 Ringmail
dtext 25 100 6208 Chainmail
dtext 25 120 6208 Studded/Leather
dtext 25 140 6208 Crystal
dtext 25 160 6208 Bone
dtext 15 180 0112 Weapons
dtext 15 200 0112 Bows
dtext 15 220 0112 Mounts
dtext 15 240 0112 Bottles
dtext 15 260 0112 Imbues
dtext 15 415 0112 Misc
LOCAL.VALUE=<src.tag0.cashpoints>
IF (<LOCAL.VALUE> = 0)
dtext 100 448 6208 0 Gp
ELSEIF (<LOCAL.VALUE> >= 1000) && (<LOCAL.VALUE> <= 9999)
LOCAL.NEWHALF=<dLOCAL.VALUE>>
dtext 100 448 6208 <dLOCAL.newhalf> Gp
ELSEIF (<LOCAL.VALUE> >= 10000) && (<LOCAL.VALUE> <= 99999)
LOCAL.NEWHALF=<STRSUB 0 2 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 2 3 <dLOCAL.VALUE>>
dtext 100 448 6208 <dLOCAL.newhalf><LOCAL.newhalf2> Gp
ELSEIF (<LOCAL.VALUE> >= 100000) && (<LOCAL.VALUE> <= 999999)
LOCAL.NEWHALF=<STRSUB 0 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 3 3 <dLOCAL.VALUE>>
dtext 100 448 6208 <dLOCAL.newhalf><LOCAL.newhalf2> Gp
ELSEIF (<LOCAL.VALUE> >= 1000000) && (<LOCAL.VALUE> <= 9999999)
LOCAL.NEWHALF=<STRSUB 0 1 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 1 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF3=,<STRSUB 4 3 <dLOCAL.VALUE>>
dtext 100 448 6208 <dLOCAL.newhalf><LOCAL.newhalf2><LOCAL.newhalf3> Gp
ELSEIF (<LOCAL.VALUE> >= 10000000) && (<LOCAL.VALUE> <= 99999999)
LOCAL.NEWHALF=<STRSUB 0 2 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 2 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF3=,<STRSUB 5 3 <dLOCAL.VALUE>>
dtext 100 448 6208 <dLOCAL.newhalf><LOCAL.newhalf2><LOCAL.newhalf3> Gp
ELSEIF (<LOCAL.VALUE> >= 100000000) && (<LOCAL.VALUE> <= 1000000000)
LOCAL.NEWHALF=<STRSUB 0 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 3 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF3=,<STRSUB 6 3 <dLOCAL.VALUE>>
dtext 100 448 6208 <dLOCAL.newhalf><LOCAL.newhalf2><LOCAL.newhalf3> Gp
endif
dtext 15 448 0112 Money earned:
dtextentry 443 3 255 25 0112

////PAGE SYSTEM
//DB.QUERY "SELECT * FROM <tag.auction_table> ORDER BY `id` DESC LIMIT 99999999";
DB.QUERY "SELECT COUNT(*) as category_allitems FROM <tag.auction_table> ORDER BY `id` DESC LIMIT 99999999";
src.ctag.totalpages=<eval (((<db.row.0.category_allitems>-1) / 8) + 1)>
dtext 715 3 0481 Items: <eval (<db.row.0.category_allitems>)>
dtext 623 448 0481 Page: [<eval <src.ctag.actualpage>>/<eval <src.ctag.totalpages>>]
if <eval (<db.row.0.category_allitems> < 1)>
dtext 380 100 0112 There is no items in the Walmart
endif

//Mysql query that fetches the rows from <src.ctag.dialogindex> to <src.ctag.dialogindex>+8
DB.QUERY "SELECT * FROM <tag.auction_table> ORDER BY `vip` DESC, `id` DESC LIMIT <eval (<src.ctag.dialogindex>)>,<eval (<src.ctag.dialogindex>+8)>";
FOR index 0 7
LOCAL.VALUE=<db.row.<eval (<local.index>)>.currentbid>
if <db.row.<eval (<local.index>)>.uid>
local.y=(((<local.index>)*45)+65)
local.x=(((<local.index>)*45)+55)
local.xs=(((<local.index>)*45)+97)
local.ys=(((<local.index>)*45)+68)
local.ys2=(((<local.index>)*45)+58)
local.buy=(((<local.index>)*45)+66)
local.name=(((<local.index>)*45)+80)
if <eval (<db.row.<eval (<local.index>)>.vip> > 0)>
dtext 380 <local.y> 014d <uid.<db.row.<eval (<local.index>)>.uid>.name> -VIP-
else
dtext 380 <local.y> 0 <uid.<db.row.<eval (<local.index>)>.uid>.name>
endif
resizepic 640 <local.ys2> 3000 100 42 //Lai naudu redz
button 759 <local.ys> 5224 5003 1 0 <eval (<db.row.<eval (<local.index>)>.id>+10)>
IF (<LOCAL.VALUE> >= 1) && (<LOCAL.VALUE> <= 9999)
LOCAL.NEWHALF=<dLOCAL.VALUE>>
dtext 650 <local.y> 0 <dLOCAL.newhalf>
ELSEIF (<LOCAL.VALUE> >= 10000) && (<LOCAL.VALUE> <= 99999)
LOCAL.NEWHALF=<STRSUB 0 2 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 2 3 <dLOCAL.VALUE>>
dtext 650 <local.y> 0 <dLOCAL.newhalf><LOCAL.newhalf2>
ELSEIF (<LOCAL.VALUE> >= 100000) && (<LOCAL.VALUE> <= 999999)
LOCAL.NEWHALF=<STRSUB 0 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 3 3 <dLOCAL.VALUE>>
dtext 650 <local.y> 0 <dLOCAL.newhalf><LOCAL.newhalf2>
ELSEIF (<LOCAL.VALUE> >= 1000000) && (<LOCAL.VALUE> <= 9999999)
LOCAL.NEWHALF=<STRSUB 0 1 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 1 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF3=,<STRSUB 4 3 <dLOCAL.VALUE>>
dtext 650 <local.y> 0 <dLOCAL.newhalf><LOCAL.newhalf2><LOCAL.newhalf3>
ELSEIF (<LOCAL.VALUE> >= 10000000) && (<LOCAL.VALUE> <= 99999999)
LOCAL.NEWHALF=<STRSUB 0 2 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 2 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF3=,<STRSUB 5 3 <dLOCAL.VALUE>>
dtext 650 <local.y> 0 <dLOCAL.newhalf><LOCAL.newhalf2><LOCAL.newhalf3>
ELSEIF (<LOCAL.VALUE> >= 100000000) && (<LOCAL.VALUE> <= 1000000000)
LOCAL.NEWHALF=<STRSUB 0 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF2=,<STRSUB 3 3 <dLOCAL.VALUE>>
LOCAL.NEWHALF3=,<STRSUB 6 3 <dLOCAL.VALUE>>
dtext 650 <local.y> 0 <dLOCAL.newhalf><LOCAL.newhalf2><LOCAL.newhalf3>
endif
tilepichue 300 <local.x> <eval <uid.<db.row.<eval (<local.index>)>.uid>.id>> <eval <uid.<db.row.<eval (<local.index>)>.uid>.color>>
resizepic 275 <local.xs> 9300 507 5 <db.row.<eval (<local.index>)>.uid>
resizepic 750 <local.buy> 9300 37 20 <db.row.<eval (<local.index>)>.uid>
dtext 758 <local.buy> 0112 Buy
dtext 650 <local.name> 0481 By <uid.<db.row.<eval (<local.index>)>.seller>.name>
if (<uid.<db.row.<eval (<local.index>)>.uid>.istalisman>)
elif (<uid.<db.row.<eval (<local.index>)>.uid>.isarmor>)
dtext 381 <local.name> 0481 Dur: <uid.<db.row.<eval (<local.index>)>.uid>.MORE1L>/<uid.<db.row.<eval (<local.index>)>.uid>.MORE1H>
ELif (<uid.<db.row.<eval (<local.index>)>.uid>.isjeweli>)
dtext 500 <local.name> 0481 Plus +<uid.<db.row.<eval (<local.index>)>.uid>.MOREX>
dtext 381 <local.name> 0481 Charges: <uid.<db.row.<eval (<local.index>)>.uid>.MOREM>
ELif (<uid.<db.row.<eval (<local.index>)>.uid>.isjewelires>)
dtext 381 <local.name> 0481 Charges: <uid.<db.row.<eval (<local.index>)>.uid>.MOREM>
ELIF (<uid.<db.row.<eval (<local.index>)>.uid>.type>==t_jewelry)
dtext 381 <local.name> 0481 Charges: <eval <uid.<db.row.<eval (<local.index>)>.uid>.tag.charge>>
ELIF (<uid.<db.row.<eval (<local.index>)>.uid>.type>==t_charm)
dtext 381 <local.name> 0481 Charges: <eval <uid.<db.row.<eval (<local.index>)>.uid>.morex>>
ELIF (<uid.<db.row.<eval (<local.index>)>.uid>.baseid>==i_treature_map)
dtext 381 <local.name> 0481 Level: <eval <uid.<db.row.<eval (<local.index>)>.uid>.tag.tlevel>>
ELIF <uid.<db.row.<eval (<local.index>)>.uid>.isweapon>
dtext 500 <local.name> 0481 Dmg: <uid.<db.row.<eval (<local.index>)>.uid>.DAM>
dtext 381 <local.name> 0481 Dur: <uid.<db.row.<eval (<local.index>)>.uid>.MORE1L>/<uid.<db.row.<eval (<local.index>)>.uid>.MORE1H>
ELIF <uid.<db.row.<eval (<local.index>)>.uid>.amount> > 1
dtext 381 <local.name> 0481 Amount: <uid.<db.row.<eval (<local.index>)>.uid>.amount>
ENDIF
endif
ENDFOR