Skip to main content
Last updated October 27, 2011 02:29, by javydreamercsw
Feedicon  

This wikipage will contain information for jWrestling developers.

You need to know Java, at least the basics, to program jWrestling. The complex stuff is in the server and Marauroa interaction.

You can go here to learn about Java and here for the coding basics.

NetBeans 7.0.1 is the current IDE used to code jWrestling. The source is stored as NetBeans projects in the repository. It'll work with previous versions but some library dependencies might not exist in previous versions of the IDE and need to be added manually.

ALL GUI related contributions must be performed with Netbeans IDE, not because I just want to but, besides it's my favorite IDE, the way Matisse works you work might be overwritten if the form file is not updated as code is generated automatically from it when it's opened. So to avoid your frustration and you work not working any modification to a file that has it's .form counterpart MUST be done in Netbeans.

It's recommended to understand the inner workings of Marauroa if you intend to add new functionality besides creating moves, matches and wrestlers. Start learning!

The following is obsolete

Creating Moves

  1. Extend games.jwrestling.core.Page.Abstract.Move or another move if this page is meant to count as another page.
  2. Populate basic Info as shown in example

package games.jwrestling.core.Page.edition.first.Move;
import games.jwrestling.core.GameObject.Edition;
import games.jwrestling.core.GameObject.MethodType;
import games.jwrestling.core.GameObject.MoveType;
import games.jwrestling.core.GameObject.KeyWord;
import games.jwrestling.core.Page.Abstract.Move;

public class Body_Slam extends Move {

public Body_Slam() {
   this.cost = 2;
   this.name = "Body Slam";
   this.Text = "Counters mad rush and high risk moves.";
   this.edition = Edition.FIRST;
   this.abilityRequired[2] = 1;
   this.counteredMoveTypes.add(MoveType.MAD_RUSH);
   this.counteredMoveTypes.add(MoveType.IN_CLOSE);
   this.keyWords.add(KeyWord.TAKEDOWN);
   this.keyWords.add(KeyWord.IMPACT);
   this.keyWords.add(KeyWord.LIFT);
   this.type = MoveType.IN_CLOSE;
   this.method = MethodType.STRENGTH;
   }
}

Explanation of Code:

  • cost: Total momentum cost. Default 0
  • name: Page name. Default ""
  • Text: back of page text. Default ""
  • edition: Page set edition
  • abilityRequired: From the total cost how many and what type of momentum is needed in the following order: Agility (0), Knowledge (1), Strength (2), Strike (3), Technical (4). So in the example we need 2 of the element 2 which are 2 strength. Default no ability required.
  • counteredMoveTypes: What move types are countered by this move. Default none
  • keyWords: Move keywords. Default none.
  • type: Move's move type. Default none.
  • method: Move's method. Default none.

Note: Bold elements MUST be set even if having a default. This is a basic setup for pages with no special properties. That scenario will be covered later.



Creating Specials

  1. Extend games.jwrestling.core.Page.Abstract.Special or another special if this page is meant to count as another page.

To be continued...


Creating Super Stars

  1. Extend games.jwrestling.core.Page.Abstract.Wrestler.
  2. Populate basic Info as shown in example:

package games.jwrestling.core.Page.edition.first.SS;
import games.jwrestling.core.GameObject.Edition;
import games.jwrestling.core.Page.Abstract.Wrestler;
import games.jwrestling.server.entity.player.Player;

public class Test extends Wrestler {
   public Test() {
      this.Name = "Test";
      this.faction = "Test Faction";
      this.HP = 71;
      this.edition = Edition.FIRST;
      this.Text = "Test Text";
      this.attributeLimits = new int[]{2, 2, -1, -1, 1};
      this.setIsMale(true);
   }
   @Override
   public int SpecialAbility() {
      return 0;
   }
   @Override
   public int SpecialEffect() {
      return 0;
   }
   @Override
   public void Effect(Player p) {
   }
   @Override
   public void drawPhase() {
      return;
   }
   @Override
   public void refreshPhase() {
      return;
   }
}

Explanation of Code:

  • faction: Wrestler's faction name. Default "" (this would change from a String to an Enum soon)
  • Text: back of page text. Default ""
  • edition: Wrestler's edition
  • attributeLimits: Momentum limits for the wrestler in the following order: Agility (0), Knowledge (1), Strength (2), Strike (3), Technical (4). So in the example 2 Agility, 2 Knowledge, Unlimited Strength, Unlimited Strike and 1 Technical. Default no limits.
  • setIsMale: Is a male super star? Default male
  • SpecialAbility: Here goes the custom code of what the wrestler does when it's special is used.
  • SpecialEffect: Basically a special ability that doesn't require a trigger.
  • Effect: Don't remember right now :P
  • drawPhase: Things that happen during the draw phase for this wrestler.
  • refreshPhase: Things that happen during the refresh phase for this wrestler.

Note: Bold elements MUST be set even if having a default. This is a basic setup for Wrestlers with no special properties. That scenario will be covered later.


 
 
Close
loading
Please Confirm
Close