17
17
import com .google .common .base .Enums ;
18
18
19
19
import world .bentobox .aoneblock .listeners .BlockListener ;
20
+ import world .bentobox .bentobox .BentoBox ;
20
21
import world .bentobox .bentobox .api .configuration .ConfigComment ;
21
22
import world .bentobox .bentobox .api .configuration .ConfigEntry ;
22
23
import world .bentobox .bentobox .api .configuration .StoreAt ;
@@ -196,9 +197,14 @@ public class Settings implements WorldSettings {
196
197
@ ConfigEntry (path = "world.island-height" )
197
198
private int islandHeight = 120 ;
198
199
200
+ @ ConfigComment ("The number of concurrent islands a player can have in the world" )
201
+ @ ConfigComment ("A value of 0 will use the BentoBox config.yml default" )
202
+ @ ConfigEntry (path = "world.concurrent-islands" )
203
+ private int concurrentIslands = 0 ;
204
+
199
205
@ ConfigComment ("Disallow team members from having their own islands." )
200
206
@ ConfigEntry (path = "world.disallow-team-member-islands" )
201
- private boolean disallowTeamMemberIslands = false ;
207
+ private boolean disallowTeamMemberIslands = true ;
202
208
203
209
@ ConfigComment ("Use your own world generator for this world." )
204
210
@ ConfigComment ("In this case, the plugin will not generate anything." )
@@ -2213,4 +2219,23 @@ public String getOffset() {
2213
2219
public void setOffset (String offset ) {
2214
2220
this .offset = offset ;
2215
2221
}
2222
+
2223
+ /**
2224
+ * @return the concurrentIslands
2225
+ */
2226
+ @ Override
2227
+ public int getConcurrentIslands () {
2228
+ if (concurrentIslands <= 0 ) {
2229
+ return BentoBox .getInstance ().getSettings ().getIslandNumber ();
2230
+ }
2231
+ return concurrentIslands ;
2232
+ }
2233
+
2234
+ /**
2235
+ * @param concurrentIslands the concurrentIslands to set
2236
+ */
2237
+ public void setConcurrentIslands (int concurrentIslands ) {
2238
+ this .concurrentIslands = concurrentIslands ;
2239
+ }
2240
+
2216
2241
}
0 commit comments