Thread: [RS2HD] Exception with shops

Results 1 to 3 of 3
  1. #1 [RS2HD] Exception with shops 
    Registered Member
    Shamon King's Avatar
    Join Date
    Aug 2007
    Posts
    3,335
    Thanks given
    90
    Thanks received
    228
    Rep Power
    1363
    Well it's obviously doing something wrong when it updates the shop to "clear" the shops out over a period of time

    Code:
    Exception in thread "GameEngine" java.lang.ClassCastException: com.rs2hd.model.I
    tem cannot be cast to com.rs2hd.model.ShopItem
            at com.rs2hd.model.Shop.updateAmounts(Shop.java:68)
            at com.rs2hd.util.ShopManager.updateAmounts(ShopManager.java:48)
            at com.rs2hd.util.ShopManager.access$000(ShopManager.java:18)
            at com.rs2hd.util.ShopManager$1.execute(ShopManager.java:31)
            at com.rs2hd.event.Event.run(Event.java:81)
            at com.rs2hd.model.World.processEvents(World.java:216)
            at com.rs2hd.model.World.tick(World.java:291)
            at com.rs2hd.GameEngine.tick(GameEngine.java:123)
            at com.rs2hd.Server.processEvents(Server.java:192)
            at com.rs2hd.Server.go(Server.java:122)
            at com.rs2hd.Main$1.run(Main.java:38)
            at java.lang.Thread.run(Unknown Source)
    Reply With Quote  
     

  2. #2  
    Programmer, Contributor, RM and Veteran




    Join Date
    Mar 2007
    Posts
    5,147
    Thanks given
    2,656
    Thanks received
    3,731
    Rep Power
    5000
    Hmm somewhere it is inserting an Item instead of a ShopItem. The shop system sucks btw, it could be better to recreate it.
    .
    Reply With Quote  
     

  3. #3  
    Donator
    Nightleaf's Avatar
    Join Date
    Apr 2008
    Posts
    440
    Thanks given
    7
    Thanks received
    18
    Rep Power
    75
    Code:
    ShopItem si = playerStock.get(i);
    Thats where it occurs.. apparently
    Reply With Quote  
     


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
  •