mirror of
https://github.com/GTNewHorizons/Gadomancy.git
synced 2026-11-27 15:23:22 +00:00
- AuraPylon added effects
This commit is contained in:
1 parent
6c5032f5d6
commit
5d366d08a4
11 files changed
+151
-52
No files matched your search
@@ -56,6 +56,7 @@ public class EffectHandler {
|
||||
orbitalsRWLock.lock();
|
||||
try {
|
||||
orbitals.add(orbital);
|
||||
orbital.registered = true;
|
||||
} finally {
|
||||
orbitalsRWLock.unlock();
|
||||
}
|
||||
@@ -70,6 +71,7 @@ public class EffectHandler {
|
||||
orbitalsRWLock.lock();
|
||||
try {
|
||||
orbitals.remove(orbital);
|
||||
orbital.registered = false;
|
||||
} finally {
|
||||
orbitalsRWLock.unlock();
|
||||
}
|
||||
@@ -81,6 +83,20 @@ public class EffectHandler {
|
||||
Orbital.tickOrbitals(orbitals);
|
||||
}
|
||||
|
||||
public void clear() {
|
||||
new Thread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
orbitalsRWLock.lock();
|
||||
try {
|
||||
orbitals.clear();
|
||||
} finally {
|
||||
orbitalsRWLock.unlock();
|
||||
}
|
||||
}
|
||||
}).start();
|
||||
}
|
||||
|
||||
public static class NonReentrantReentrantLock extends ReentrantLock {
|
||||
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user