Skip to content
This repository was archived by the owner on Oct 28, 2025. It is now read-only.

Commit ac8e013

Browse files
committed
AWE-API: AWE 3.2.3 changes
ADD: Added messaging system support ADD: Added progress bar minimum number of blocks ADD: Added configurable number of blocks to IPlayerEntry
1 parent 2b02952 commit ac8e013

File tree

3 files changed

+95
-4
lines changed

3 files changed

+95
-4
lines changed
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
/*
2+
* AsyncWorldEdit Premium is a commercial version of AsyncWorldEdit. This software
3+
* has been sublicensed by the software original author according to p7 of
4+
* AsyncWorldEdit license.
5+
*
6+
* AsyncWorldEdit Premium - donation version of AsyncWorldEdit, a performance
7+
* improvement plugin for Minecraft WorldEdit plugin.
8+
*
9+
* Copyright (c) 2015, SBPrime <https://github.com/SBPrime/>
10+
*
11+
* All rights reserved.
12+
*
13+
* 1. You may:
14+
* install and use AsyncWorldEdit in accordance with the Software documentation
15+
* and pursuant to the terms and conditions of this license
16+
* 2. You may not:
17+
* sell, redistribute, encumber, give, lend, rent, lease, sublicense, or otherwise
18+
* transfer Software, or any portions of Software, to anyone without the prior
19+
* written consent of Licensor
20+
* 3. The original author of the software is allowed to change the license
21+
* terms or the entire license of the software as he sees fit.
22+
* 4. The original author of the software is allowed to sublicense the software
23+
* or its parts using any license terms he sees fit.
24+
*
25+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
26+
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
27+
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
28+
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
29+
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
30+
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
31+
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
32+
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
33+
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
34+
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35+
*/
36+
package org.primesoft.asyncworldedit.api;
37+
38+
/**
39+
*
40+
* @author SBPrime
41+
*/
42+
public enum MessageSystem {
43+
44+
TALKATIVE("Talkative"),
45+
BAR("Bar"),
46+
CHAT("Chat");
47+
48+
private final String m_name;
49+
50+
public String getName() {
51+
return m_name;
52+
}
53+
54+
private MessageSystem(String name) {
55+
m_name = name;
56+
}
57+
}

AsyncWorldEdit-api/src/org/primesoft/asyncworldedit/api/configuration/IPermissionGroup.java

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,16 +90,24 @@ public interface IPermissionGroup {
9090
*/
9191
int getRendererTime();
9292

93+
/**
94+
* The minimum number of blocks to show the progress bar
95+
*
96+
* @return
97+
*/
98+
int getBarApiProgresMinBlocks();
99+
93100
/**
94101
* Use the bar api to display progress
95102
*
96103
* @return
97104
*/
98105
boolean isBarApiProgressEnabled();
99-
106+
100107
/**
101108
* Is the undo disabled
102-
* @return
109+
*
110+
* @return
103111
*/
104112
boolean isUndoDisabled();
105113

@@ -130,5 +138,5 @@ public interface IPermissionGroup {
130138
* @return
131139
*/
132140
boolean isTalkative();
133-
141+
134142
}

AsyncWorldEdit-api/src/org/primesoft/asyncworldedit/api/playerManager/IPlayerEntry.java

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737

3838
import java.util.UUID;
3939
import org.bukkit.entity.Player;
40+
import org.primesoft.asyncworldedit.api.MessageSystem;
4041
import org.primesoft.asyncworldedit.api.configuration.IPermissionGroup;
4142
import org.primesoft.asyncworldedit.api.permissions.IPermission;
4243

@@ -87,7 +88,7 @@ public interface IPlayerEntry {
8788
* @return
8889
*/
8990
Object getWaitMutex();
90-
91+
9192
/**
9293
* Get the
9394
* @param permission
@@ -147,4 +148,29 @@ public interface IPlayerEntry {
147148
*/
148149
void update(Player player, IPermissionGroup permissionGroup);
149150

151+
/**
152+
* Update the messaging system
153+
* @param system
154+
* @param state
155+
*/
156+
void setMessaging(MessageSystem system, boolean state);
157+
158+
/**
159+
* Get the messaging system status
160+
* @param system
161+
* @return
162+
*/
163+
boolean getMessaging(MessageSystem system);
164+
165+
/**
166+
* Get the number of blocks rendered each run
167+
* @return
168+
*/
169+
int getRenderBlocks();
170+
171+
/**
172+
* Set the number of rendered blocks
173+
* @param b The new speed (null for default)
174+
*/
175+
void setRenderBlocks(Integer b);
150176
}

0 commit comments

Comments
 (0)