Clean up a bunch of TODOs that are no longer relevant
This commit is contained in:
@@ -79,7 +79,6 @@ public final class WizardryEventHandler {
|
|||||||
public static void onPlayerLoggedInEvent(PlayerLoggedInEvent event){
|
public static void onPlayerLoggedInEvent(PlayerLoggedInEvent event){
|
||||||
// When a player logs in, they are sent the glyph data, server settings and spell properties.
|
// When a player logs in, they are sent the glyph data, server settings and spell properties.
|
||||||
if(event.player instanceof EntityPlayerMP){
|
if(event.player instanceof EntityPlayerMP){
|
||||||
// TODO: Move these to handler classes where possible
|
|
||||||
SpellGlyphData.get(event.player.world).sync((EntityPlayerMP)event.player);
|
SpellGlyphData.get(event.player.world).sync((EntityPlayerMP)event.player);
|
||||||
SpellEmitterData.get(event.player.world).sync((EntityPlayerMP)event.player);
|
SpellEmitterData.get(event.player.world).sync((EntityPlayerMP)event.player);
|
||||||
Wizardry.settings.sync((EntityPlayerMP)event.player);
|
Wizardry.settings.sync((EntityPlayerMP)event.player);
|
||||||
|
|||||||
@@ -164,7 +164,6 @@ public class ModelRendererExtended extends ModelRenderer {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void postRender(float scale){
|
public void postRender(float scale){
|
||||||
// TODO: It may just be easier to hardcode the item rotation part of the animation as well
|
|
||||||
// Exactly the same setup as above, just add item rotation/translation fields and setters
|
// Exactly the same setup as above, just add item rotation/translation fields and setters
|
||||||
// float angle = 1;
|
// float angle = 1;
|
||||||
// float radius = 10;
|
// float radius = 10;
|
||||||
|
|||||||
@@ -426,7 +426,7 @@ public class GuiLectern extends GuiSpellInfo implements ISpellSortable {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!availableSpells.contains(currentSpell)) currentSpell = Spells.none; // TODO: Do we want this?
|
if(!availableSpells.contains(currentSpell)) currentSpell = Spells.none;
|
||||||
|
|
||||||
updateMatchingSpells();
|
updateMatchingSpells();
|
||||||
updateButtonVisiblity();
|
updateButtonVisiblity();
|
||||||
|
|||||||
@@ -247,7 +247,7 @@ public class CommandCastSpell extends CommandBase {
|
|||||||
|
|
||||||
if(data != null){
|
if(data != null){
|
||||||
if(data.isCasting()){
|
if(data.isCasting()){
|
||||||
data.stopCastingContinuousSpell(); // TODO: Where should this go now?
|
data.stopCastingContinuousSpell(); // I think on balance this is quite a nice feature to leave in
|
||||||
}else{
|
}else{
|
||||||
|
|
||||||
data.startCastingContinuousSpell(spell, modifiers, duration);
|
data.startCastingContinuousSpell(spell, modifiers, duration);
|
||||||
|
|||||||
@@ -31,7 +31,6 @@ public class EntityStormElemental extends EntitySummonedCreature implements ISpe
|
|||||||
public EntityStormElemental(World world){
|
public EntityStormElemental(World world){
|
||||||
super(world);
|
super(world);
|
||||||
// For some reason this can't be in initEntityAI
|
// For some reason this can't be in initEntityAI
|
||||||
// TESTME: May need to be inside a !world.isRemote check.
|
|
||||||
this.tasks.addTask(0, this.spellAttackAI);
|
this.tasks.addTask(0, this.spellAttackAI);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -252,7 +252,6 @@ public class EntityWizard extends EntityCreature implements INpc, IMerchant, ISp
|
|||||||
// Apparently nothing goes here, and nothing's here in EntityVillager either...
|
// Apparently nothing goes here, and nothing's here in EntityVillager either...
|
||||||
}
|
}
|
||||||
|
|
||||||
// TESTME: Should this be getName instead?
|
|
||||||
@Override
|
@Override
|
||||||
public ITextComponent getDisplayName(){
|
public ITextComponent getDisplayName(){
|
||||||
|
|
||||||
|
|||||||
@@ -95,8 +95,6 @@ public class Paralysis extends SpellRay {
|
|||||||
|
|
||||||
// See WizardryClientEventHandler for prevention of players' movement under the effects of paralysis
|
// See WizardryClientEventHandler for prevention of players' movement under the effects of paralysis
|
||||||
|
|
||||||
// TODO: (Animated?) screen overlay effect for paralysed players in first-person
|
|
||||||
|
|
||||||
@SubscribeEvent
|
@SubscribeEvent
|
||||||
public static void onLivingUpdateEvent(LivingUpdateEvent event){
|
public static void onLivingUpdateEvent(LivingUpdateEvent event){
|
||||||
// Disables entities' AI when under the effects of paralysis and re-enables it on the last update of the effect
|
// Disables entities' AI when under the effects of paralysis and re-enables it on the last update of the effect
|
||||||
|
|||||||
@@ -22,7 +22,6 @@ public class PocketWorkbench extends Spell {
|
|||||||
@Override
|
@Override
|
||||||
public boolean cast(World world, EntityPlayer caster, EnumHand hand, int ticksInUse, SpellModifiers modifiers){
|
public boolean cast(World world, EntityPlayer caster, EnumHand hand, int ticksInUse, SpellModifiers modifiers){
|
||||||
|
|
||||||
// TODO: Investigate possible item duplication bug with this spell. So far I have been unable to recreate it.
|
|
||||||
if(!world.isRemote){
|
if(!world.isRemote){
|
||||||
caster.openGui(Wizardry.instance, WizardryGuiHandler.PORTABLE_CRAFTING, world, (int)caster.posX,
|
caster.openGui(Wizardry.instance, WizardryGuiHandler.PORTABLE_CRAFTING, world, (int)caster.posX,
|
||||||
(int)caster.posY, (int)caster.posZ);
|
(int)caster.posY, (int)caster.posZ);
|
||||||
|
|||||||
@@ -148,7 +148,7 @@ public class Possession extends SpellRay {
|
|||||||
if(!shootSpell(world, origin, look, caster, ticksInUse, modifiers)) return false;
|
if(!shootSpell(world, origin, look, caster, ticksInUse, modifiers)) return false;
|
||||||
|
|
||||||
// if(casterSwingsArm(world, caster, hand, ticksInUse, modifiers)) caster.swingArm(hand);
|
// if(casterSwingsArm(world, caster, hand, ticksInUse, modifiers)) caster.swingArm(hand);
|
||||||
this.playSound(world, caster, ticksInUse, -1, modifiers, "possess"); // TODO: There must be a better way...
|
this.playSound(world, caster, ticksInUse, -1, modifiers, "possess");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -305,7 +305,7 @@ public abstract class Spell extends IForgeRegistryEntry.Impl<Spell> implements C
|
|||||||
.map(s -> s.properties).toArray(SpellProperties[]::new)));
|
.map(s -> s.properties).toArray(SpellProperties[]::new)));
|
||||||
}else{
|
}else{
|
||||||
// On the client side, wipe the spell properties so the new ones can be set
|
// On the client side, wipe the spell properties so the new ones can be set
|
||||||
// TESTME: Can we guarantee this happens before the packet arrives?
|
// Not sure if we can guarantee this happens before the packet arrives, but it hasn't caused any problems yet!
|
||||||
clearProperties();
|
clearProperties();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ public class TileEntityBookshelf extends TileEntityLockableLoot implements ITick
|
|||||||
natural = nbt.getBoolean(NATURAL_NBT_KEY);
|
natural = nbt.getBoolean(NATURAL_NBT_KEY);
|
||||||
|
|
||||||
if(!this.checkLootAndRead(nbt)){
|
if(!this.checkLootAndRead(nbt)){
|
||||||
// TODO: Replace with ItemStackHelper#loadAllItems
|
|
||||||
NBTTagList tagList = nbt.getTagList("Inventory", NBT.TAG_COMPOUND);
|
NBTTagList tagList = nbt.getTagList("Inventory", NBT.TAG_COMPOUND);
|
||||||
|
|
||||||
for(int i = 0; i < tagList.tagCount(); i++){
|
for(int i = 0; i < tagList.tagCount(); i++){
|
||||||
@@ -211,8 +211,6 @@ public class TileEntityBookshelf extends TileEntityLockableLoot implements ITick
|
|||||||
|
|
||||||
if(!this.checkLootAndWrite(nbt)){
|
if(!this.checkLootAndWrite(nbt)){
|
||||||
|
|
||||||
// TODO: Replace with ItemStackHelper#saveAllItems
|
|
||||||
|
|
||||||
NBTTagList itemList = new NBTTagList();
|
NBTTagList itemList = new NBTTagList();
|
||||||
|
|
||||||
for(int i = 0; i < getSizeInventory(); i++){
|
for(int i = 0; i < getSizeInventory(); i++){
|
||||||
|
|||||||
@@ -200,7 +200,6 @@ public abstract class WorldGenWizardryStructure implements IWorldGenerator {
|
|||||||
|
|
||||||
// To properly minimise cascading worldgen lag, the method below returns the position where the corner needs
|
// To properly minimise cascading worldgen lag, the method below returns the position where the corner needs
|
||||||
// to be such that the original structure's NW (-X, -Z) corner is at the origin.
|
// to be such that the original structure's NW (-X, -Z) corner is at the origin.
|
||||||
// TODO: Actually this may not truly minimise cascading, hmmm
|
|
||||||
origin = template.getZeroPositionWithTransform(origin, settings.getMirror(), settings.getRotation());
|
origin = template.getZeroPositionWithTransform(origin, settings.getMirror(), settings.getRotation());
|
||||||
|
|
||||||
spawnStructure(random, world, origin, template, settings, structureFile);
|
spawnStructure(random, world, origin, template, settings, structureFile);
|
||||||
|
|||||||
Reference in New Issue
Block a user