Very bad error

Help
2005-08-06
2013-06-06
  • Nobody/Anonymous

    After my serer runs a while where there's more users, then users can't really move anymore, all of them they try to move but will bounce back to where they come from here is the stack trace that i keep getting on th server when i look at the log:

    2005-08-05 21:33:27.095 (11)    X       StendhalRPRuleProcessor::beginTurn      null
    2005-08-05 21:33:27.095 (11)    X       StendhalRPRuleProcessor::beginTurn      Exception stackTrace:
      marauroa.server.game.RPWorld.remove(RPWorld.java:138)
      games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:343)
      games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:294)
      games.stendhal.server.entity.npc.NPC.onDead(NPC.java:122)
      games.stendhal.server.entity.creature.Creature.onDead(Creature.java:184)
      games.stendhal.server.StendhalRPRuleProcessor.beginTurn(StendhalRPRuleProcessor.java:785)
      marauroa.server.game.RPServerManager.run(RPServerManager.java:490)

     
    • Nobody/Anonymous

      Please help with this, as my website has lots of players who loved this game the first day it launched, but every few hours the server gets this problem and must be manually kill the java process and restart

      thanks, and great work!

       
    • Nobody/Anonymous

      2005-08-05 22:46:53.543 (11)    X       RPWorld::remove RP Object [RPObject.ID [id=881 zoneid=dungeon_000]] not found
      2005-08-05 22:46:53.552 (11)    X       RPWorld::remove Exception stackTrace:
        marauroa.server.game.MarauroaRPZone.remove(MarauroaRPZone.java:110)
        marauroa.server.game.RPWorld.remove(RPWorld.java:133)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:343)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:294)
        games.stendhal.server.entity.npc.NPC.onDead(NPC.java:122)
        games.stendhal.server.entity.creature.Creature.onDead(Creature.java:184)
        games.stendhal.server.StendhalRPRuleProcessor.beginTurn(StendhalRPRuleProcessor.java:785)
        marauroa.server.game.RPServerManager.run(RPServerManager.java:490)

      2005-08-05 22:46:53.553 (11)    X       StendhalRPRuleProcessor::beginTurn      null
      2005-08-05 22:46:53.553 (11)    X       StendhalRPRuleProcessor::beginTurn      Exception stackTrace:
        marauroa.server.game.RPWorld.remove(RPWorld.java:138)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:343)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:294)
        games.stendhal.server.entity.npc.NPC.onDead(NPC.java:122)
        games.stendhal.server.entity.creature.Creature.onDead(Creature.java:184)
        games.stendhal.server.StendhalRPRuleProcessor.beginTurn(StendhalRPRuleProcessor.java:785)
        marauroa.server.game.RPServerManager.run(RPServerManager.java:490)

       
    • Matthias Totz

      Matthias Totz - 2005-08-06

      what versions of stendhal/marauroa/mysql you're using?

      if this error occours the next time, do a
      SELECT * FROM rpattribute where object_id = 881
      and substitute the number with the numer from the stack-trace
      [RPObject.ID [id=881...]] <- here it is 881
      (you may remove personal data from the result if you think you need to)

      this is to find out what object is the bad one (i think it is a sheep)

      what is the address for your server?

       
    • Matthias Totz

      Matthias Totz - 2005-08-06

      Sorry, wrong sql query. Use:

      select * from rpattribute where object_id in
      (
      SELECT object_id FROM rpattribute where name = 'id' and value = '881'
      )

      Again, substitute '881' with the id from the stacktrace.

       
    • Nobody/Anonymous

      ok i'll do that.. it's gonna take a while since it only happens when there are a few players..

      here it my server address vnl-online.com:32160

      thanks for helping

       
    • Nobody/Anonymous

      http://vnl-online.com

      if you register to my website, u will automatically be registered into stendhal, then once u login go to "lounge" and there wil be a button called "Vnl-RPG!" and that's how players join.

      Thanks again!

       
    • Nobody/Anonymous

      sorry here are the specs

      mysql 4.1.10a-max
      stendhal-server-0.31
      marauroa-1.03

       
    • Nobody/Anonymous

      Here it happened again with this stacktrace, note that this chunk of stacktrace doesn't just appear once when my server is all screwed.  the log file is logging this exact same trace over and over again infinitly and players just can't go  anhywhere:

      2005-08-06 10:39:56.077 (11)    X       RPWorld::remove RP Object [RPObject.ID [id=1470 zoneid=dungeon_000]] not found
      2005-08-06 10:39:56.078 (11)    X       RPWorld::remove Exception stackTrace:
        marauroa.server.game.MarauroaRPZone.remove(MarauroaRPZone.java:110)
        marauroa.server.game.RPWorld.remove(RPWorld.java:133)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:343)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:294)
        games.stendhal.server.entity.npc.NPC.onDead(NPC.java:122)
        games.stendhal.server.entity.creature.Creature.onDead(Creature.java:184)
        games.stendhal.server.StendhalRPRuleProcessor.beginTurn(StendhalRPRuleProcessor.java:785)
        marauroa.server.game.RPServerManager.run(RPServerManager.java:490)

      2005-08-06 10:39:56.078 (11)    X       StendhalRPRuleProcessor::beginTurn      null
      2005-08-06 10:39:56.078 (11)    X       StendhalRPRuleProcessor::beginTurn      Exception stackTrace:
        marauroa.server.game.RPWorld.remove(RPWorld.java:138)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:343)
        games.stendhal.server.entity.RPEntity.onDead(RPEntity.java:294)
        games.stendhal.server.entity.npc.NPC.onDead(NPC.java:122)
        games.stendhal.server.entity.creature.Creature.onDead(Creature.java:184)
        games.stendhal.server.StendhalRPRuleProcessor.beginTurn(StendhalRPRuleProcessor.java:785)
        marauroa.server.game.RPServerManager.run(RPServerManager.java:490)

      When I issue this SQL " select * from rpattribute where object_id in (SELECT object_id FROM rpattribute where name = 'id' and value = '1470');"

      there are no records returned.

      Perhaps that's the problem?

       
    • Nobody/Anonymous

      just curious about that query, why not just SELECT * FROM rpattribute where name = 'id' and value = '881'   instead of a subquery of the same table?

       
    • Nobody/Anonymous

      next time it happens i'll issue "SELECT * FROM rpattribute where name like 'id' and value like '1470';"

      using the "like" instead of "="

       
    • Nobody/Anonymous

      i just tried the SQL again and again I have no record returned.  Any suggestions?

       
    • Nobody/Anonymous

      I can't wait anymore, players are getting mad everytime server crashes, and i must manually kill process and restart.  so i changed the class:

      StendhalRPRuleProcessor::synchronized public void beginTurn():

            for(Pair<RPEntity, RPEntity> entity: entityToKill)

              {

                try{

                    entity.first().onDead(entity.second());

                }catch(Exception e){

                    System.out.println("can't dead: " + entity+" -- "+e.getMessage());

                }

              }

      I did a try catch for the line "entity.first().onDead(entity.second());"  so that it doesn't blow up there and keeps trying to remove the entity that doesn't exist.  it resolved the problem and the server can keep playing now..

      It is however a hack and i haven't the time to fix it properly.. Please let me know if you guys have a proper fix :)  thanks!

       
      • Miguel Angel Blanch Lardin

        Hi.

        Sorry for the delay.

        I have been on holiday for a month and I haven't been able to read forums during this time.

        I will work on fixing your problem as soon as possible.

        Thanks for the feedback.

         
    • Matthias Totz

      Matthias Totz - 2005-08-08

      Unfortunately I haven't found reason the NullPointerException yet.
      I would have proposed a hack similar to yours for the moment.

      I have created a bug, so it is scheduled for the next version.
      I'll notify you when this issue is solved. You may monitor this thread for updates...

      And, thanks for your bug report :)

       
    • Miguel Angel Blanch Lardin

      ok, it is fixed.
      As I see you can compile code, just modify StendhalRPAction.java

        public static boolean attack(RPEntity source,RPEntity target) throws AttributeNotFoundException, NoRPZoneException, RPObjectNotFoundException
          {
          try
            {
            StendhalRPZone zone=(StendhalRPZone)world.getRPZone(source.getID());
            if(!zone.has(target.getID()) || target.getHP()==0)
              {
              target.onAttack(source, false);
              world.modify(source);
              return false;
              }

      So that the first lines of attack method looks like this one.

      I am very sorry for this bug.

       
      • Miguel Angel Blanch Lardin

        Hehehe, It need to modify too RPEntity.java ( at server ) so that onDamage method we compare leftHP>0 ( not >= )

        If you don't find it it is possible to have inmortal HP==0 players/creatures.

         


Anonymous

Cancel  Add attachments





Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks