Added xp gain on killing NPCs, fixed some bugs, added 2 new config options

This commit is contained in:
Light2
2014-03-26 23:37:10 +01:00
parent d1a7f20177
commit c3772e3246
27 changed files with 228 additions and 208 deletions
+7
View File
@@ -103,6 +103,9 @@ public class SpawnService {
creature.setOptionsBitmask(mobileTemplate.getOptionBitmask());
creature.setPvPBitmask(mobileTemplate.getPvpBitmask());
creature.setStfFilename("mob/creature_names"); // TODO: set other STFs for NPCs other than creatures
creature.setStfName(mobileTemplate.getCreatureName());
creature.setHeight(mobileTemplate.getScale());
int difficulty = mobileTemplate.getDifficulty();
creature.setDifficulty((byte) difficulty);
if(level != -1)
@@ -171,6 +174,10 @@ public class SpawnService {
return creature;
}
public CreatureObject spawnCreature(String mobileTemplate, String planetName, long cellId, float x, float y, float z, float qW, float qX, float qY, float qZ, int level) {
return spawnCreature(mobileTemplate, planetName, cellId, x, y, z, 1, 0, 0, 0, (short) level);
}
public CreatureObject spawnCreature(String mobileTemplate, String planetName, long cellId, float x, float y, float z) {
return spawnCreature(mobileTemplate, planetName, cellId, x, y, z, 1, 0, 0, 0, (short) -1);
}