Thread: Infinity shop items

Results 1 to 5 of 5
  1. #1 Infinity shop items 
    Registered Member
    Join Date
    Aug 2008
    Posts
    492
    Thanks given
    1
    Thanks received
    8
    Rep Power
    10
    Used swats tutorial http://www.rune-server.org/showthread.php?t=138635
    How would I make it so the item is actually infinite amount, when you buy all items from any amount of stock instead of 0 it shows infinity symbol and you can't buy when its present.

    Originally it looked like this outStream.writeDWord_v2(server.shopHandler.ShopIte msN[ShopID][i]);
    swat says change it to this
    outStream.writeDWord_v2(0);

    now I know this just changes the value of 0 with the symbol but how would i make it so it actually has infinity item amounts

    Thanks

    rep++
    Message if you can hook up a domain or sweet banner for free
     

  2. #2  
    Registered Member

    Join Date
    Aug 2007
    Posts
    2,395
    Thanks given
    2
    Thanks received
    63
    Rep Power
    558
    server.shopHandler.ShopItemsN[ShopID][i] = #
    You just write 0 to the client to make the client know it has to show the infinite symbol
    but on your serverside you have the amount (#) you did set
     

  3. #3  
    Registered Member
    Join Date
    Aug 2008
    Posts
    492
    Thanks given
    1
    Thanks received
    8
    Rep Power
    10
    okay thanks thought it was something like that
    Message if you can hook up a domain or sweet banner for free
     

  4. #4  
    Extreme Donator

    Wolf's Avatar
    Join Date
    Jul 2006
    Age
    34
    Posts
    398
    Thanks given
    0
    Thanks received
    2
    Rep Power
    177
    I think I'm misunderstanding what you're asking here, but if you want a shop to sell an item but not subtract the shop's stock pile, you'd go to your "buyItem" method and find this bit of code:
    Code:
    server.shopHandler.ShopItemsN[MyShopID][fromSlot] -= 1;
    That deletes 1 quantity of the item from the shop when you buy it, you could just comment that out if you like.

    RuneCMS member / Early Sythe member
    RS-Server ex-admin [Member #38]
    Dodian ex-admin / developer
    SRL Developer
    MITB member

    Project16/Flight creator
     

  5. #5  
    Ex RSPS-cleaner

    SWAT's Avatar
    Join Date
    Aug 2007
    Age
    30
    Posts
    5,484
    Thanks given
    403
    Thanks received
    599
    Rep Power
    3609
    Quote Originally Posted by Jonas++ View Post
    You just write 0 to the client to make the client know it has to show the infinite symbol
    but on your serverside you have the amount (#) you did set
    you dont have to change that.

    you dont need to delete/change the amount

    To answer the question of the thread, go to shops.cfg and just make the stock 2000.000.000. all it does is write the 0 so the client draws infinity icon, but it wont effect the stock amount
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •