forked from MagicBane/Server
Project cleanup pre merge.
This commit is contained in:
@@ -22,41 +22,40 @@ import java.sql.SQLException;
|
||||
|
||||
public class RemoveEffectPowerAction extends AbstractPowerAction {
|
||||
|
||||
|
||||
public EffectSourceType sourceType;
|
||||
private boolean removeAll;
|
||||
|
||||
public RemoveEffectPowerAction(ResultSet rs) throws SQLException {
|
||||
super(rs);
|
||||
String effectTypeToRemove = rs.getString("effectSourceToRemove").replace("-", "").trim();
|
||||
sourceType = EffectSourceType.GetEffectSourceType(effectTypeToRemove);
|
||||
int flags = rs.getInt("flags");
|
||||
this.removeAll = ((flags & 2) != 0) ? true : false;
|
||||
}
|
||||
public EffectSourceType sourceType;
|
||||
private boolean removeAll;
|
||||
|
||||
public RemoveEffectPowerAction(ResultSet rs) throws SQLException {
|
||||
super(rs);
|
||||
String effectTypeToRemove = rs.getString("effectSourceToRemove").replace("-", "").trim();
|
||||
sourceType = EffectSourceType.GetEffectSourceType(effectTypeToRemove);
|
||||
int flags = rs.getInt("flags");
|
||||
this.removeAll = ((flags & 2) != 0) ? true : false;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void _startAction(AbstractCharacter source, AbstractWorldObject awo, Vector3fImmutable targetLoc, int trains, ActionsBase ab, PowersBase pb) {
|
||||
if (awo != null) {
|
||||
|
||||
|
||||
if (this.removeAll)
|
||||
awo.removeEffectBySource(this.sourceType, trains, true);
|
||||
else
|
||||
if (this.getIDString().equals("SNC-003A"))
|
||||
trains = 40;
|
||||
awo.removeEffectBySource(this.sourceType, trains, false);
|
||||
}
|
||||
}
|
||||
@Override
|
||||
protected void _startAction(AbstractCharacter source, AbstractWorldObject awo, Vector3fImmutable targetLoc, int trains, ActionsBase ab, PowersBase pb) {
|
||||
if (awo != null) {
|
||||
|
||||
@Override
|
||||
protected void _handleChant(AbstractCharacter source, AbstractWorldObject target, Vector3fImmutable targetLoc, int trains, ActionsBase ab, PowersBase pb) {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void _startAction(AbstractCharacter source, AbstractWorldObject awo, Vector3fImmutable targetLoc,
|
||||
int numTrains, ActionsBase ab, PowersBase pb, int duration) {
|
||||
// TODO Auto-generated method stub
|
||||
if (this.removeAll)
|
||||
awo.removeEffectBySource(this.sourceType, trains, true);
|
||||
else if (this.getIDString().equals("SNC-003A"))
|
||||
trains = 40;
|
||||
awo.removeEffectBySource(this.sourceType, trains, false);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@Override
|
||||
protected void _handleChant(AbstractCharacter source, AbstractWorldObject target, Vector3fImmutable targetLoc, int trains, ActionsBase ab, PowersBase pb) {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void _startAction(AbstractCharacter source, AbstractWorldObject awo, Vector3fImmutable targetLoc,
|
||||
int numTrains, ActionsBase ab, PowersBase pb, int duration) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user