forked from 2009Scape/Server
Goblin Village SIgn Post Soft fix
This commit is contained in:
parent
380c4aa09b
commit
f0cde9d264
2 changed files with 27 additions and 1 deletions
|
|
@ -0,0 +1,26 @@
|
|||
package plugin.interaction.object;
|
||||
|
||||
import org.crandor.cache.def.impl.ObjectDefinition;
|
||||
import org.crandor.game.interaction.OptionHandler;
|
||||
import org.crandor.game.node.Node;
|
||||
import org.crandor.game.node.entity.player.Player;
|
||||
import org.crandor.plugin.InitializablePlugin;
|
||||
import org.crandor.plugin.Plugin;
|
||||
|
||||
@InitializablePlugin
|
||||
public class GoblinVillagePopulationPlugin extends OptionHandler {
|
||||
|
||||
@Override
|
||||
public Plugin<Object> newInstance(Object arg) throws Throwable {
|
||||
ObjectDefinition.forId(31301).getConfigurations().put("option:read", this);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean handle(Player player, Node node, String option) {
|
||||
int population = 26; //TODO: Find out how to get all goblins in the area.
|
||||
player.getDialogueInterpreter().sendPlainMessage(false, "Welcome to Goblin Village.", "Current population: " + population);
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -108,7 +108,7 @@ public class ReadSignPostPlugin extends OptionHandler {
|
|||
ObjectDefinition.forId(31298).getConfigurations().put("option:read", this);
|
||||
ObjectDefinition.forId(31299).getConfigurations().put("option:read", this);
|
||||
ObjectDefinition.forId(31300).getConfigurations().put("option:read", this);
|
||||
ObjectDefinition.forId(31301).getConfigurations().put("option:read", this);
|
||||
// ObjectDefinition.forId(31301).getConfigurations().put("option:read", this);//goblin village
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue