Thread: saving problem

Results 1 to 4 of 4
  1. #1 saving problem 
    Registered Member
    Join Date
    Aug 2016
    Age
    20
    Posts
    164
    Thanks given
    26
    Thanks received
    3
    Rep Power
    63
    Basically the problem is, the trading post has an option for you to search for a player and it will open his shop, and if he has posted an item in there it will show, but if u log out and log back in and try and do it, it will not show.


    the code is here
    public static void loadPlayerName(Player c, String playerName) {
    c.lookup = playerName;
    c.searchId = 2;
    c.getPA().showInterface(48000);
    c.getPA().sendFrame126("Trading Post - Searching for player: " + playerName, 48019);

    List<Sale> sales = new LinkedList<Sale>();

    for(String s : new File("./data/tradingpost/players/").list()) {
    s = s.substring(0, s.indexOf(".")).toLowerCase();
    if(s.contains(playerName.toLowerCase()))
    sales.addAll(getSales(s));
    }

    displayResults(sales, c);
    }
    There also a problem were we have "my offers" so that they can cancel the offer if they want to, but it resets when they log so they cant cancel there items of, unless it gets bought then thats how they get it off.

    that only has a
    loadPlayersListings(c);
    and then litreally when u log repeats itself but doesnt keep the listed items before the log.


    its hard to explain as i dont know most if it myself as it looks like someone has literally just left a project half finished.

    any help is appreciated, dont mind repping at all.
    Reply With Quote  
     

  2. #2  
    Registered Member
    TheChosenOne's Avatar
    Join Date
    Jan 2013
    Posts
    970
    Thanks given
    47
    Thanks received
    156
    Rep Power
    365
    For both problems: are you sure these method are called? You can confirm by having it spit out a debug message in the console.
    My informative threads:
    [Only registered and activated users can see links. ]
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Aug 2016
    Age
    20
    Posts
    164
    Thanks given
    26
    Thanks received
    3
    Rep Power
    63
    Quote Originally Posted by TheChosenOne View Post
    For both problems: are you sure these method are called? You can confirm by having it spit out a debug message in the console.
    see i thought it wasnt getting called aswell, im not entirely to coding but this who system could of been done a lot cleaner, it has missing parts, add my discord #Aaron 6449

    bump

    bump
    Reply With Quote  
     

  4. #4  
    Donator


    Join Date
    Jan 2010
    Age
    25
    Posts
    3,953
    Thanks given
    254
    Thanks received
    460
    Rep Power
    511
    That code is like 2,5 years old, i suggest just rewriting it as it is writen pretty bad
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

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

Similar Threads

  1. [525] Saving Problem?
    By owner jacob in forum Help
    Replies: 10
    Last Post: 01-05-2010, 01:09 AM
  2. scaperune saving problem
    By rsmzone in forum Help
    Replies: 9
    Last Post: 08-01-2009, 02:04 AM
  3. 525 Saving Problem.
    By Mr NYC in forum Help
    Replies: 7
    Last Post: 05-12-2009, 01:01 AM
  4. [525] XML saving problems
    By Nikki in forum Help
    Replies: 3
    Last Post: 05-10-2009, 02:42 AM
  5. acc saving problem
    By mige5 in forum Help
    Replies: 4
    Last Post: 09-27-2008, 04:50 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •