Package games.stendhal.server.maps

Source Code of games.stendhal.server.maps.MockStendlRPWorld

/* $Id: MockStendlRPWorld.java,v 1.17 2010/09/19 01:29:02 nhnb Exp $ */
/***************************************************************************
*                   (C) Copyright 2003-2010 - Stendhal                    *
***************************************************************************
***************************************************************************
*                                                                         *
*   This program is free software; you can redistribute it and/or modify  *
*   it under the terms of the GNU General Public License as published by  *
*   the Free Software Foundation; either version 2 of the License, or     *
*   (at your option) any later version.                                   *
*                                                                         *
***************************************************************************/
package games.stendhal.server.maps;

import games.stendhal.server.core.engine.RPClassGenerator;
import games.stendhal.server.core.engine.StendhalRPWorld;
import marauroa.common.game.RPObject;

public class MockStendlRPWorld extends StendhalRPWorld {

  @Override
  public void modify(final RPObject object) {
  }

  protected void createRPClasses() {
    new RPClassGenerator().createRPClasses();
  }
 
  public static StendhalRPWorld get() {
    if (!(instance instanceof MockStendlRPWorld)) {
      instance = new MockStendlRPWorld();
      ((MockStendlRPWorld) instance).createRPClasses();
    }
    return instance;
  }

  @Override
  protected void initialize() {
  }
 
  public static void  reset() {
    instance = null;
  }

}
TOP

Related Classes of games.stendhal.server.maps.MockStendlRPWorld

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.