Skip to content
This repository was archived by the owner on May 15, 2023. It is now read-only.

Commit eef91f6

Browse files
committed
Adding acis, update lucera
aCis - initial commit - Patch diff for minimal installation process - also contains voiced command handler Lucera - Fixed output paths on project dir - Updated dictionary and workspace project files - Added missing default values on config for console RGB colors - HWID Protection fallback to IP that fallback into player name in case of null - refactor ips to fingerprint - removed ip check - added objects null coalesce check on HWID, IP, player name on this order - Game console string seperator - Updated script version
1 parent 344942f commit eef91f6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+2548
-50
lines changed

Interlude/aCis/VDSystem/.idea/.gitignore

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/artifacts/VDSystem.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/dictionaries/CPU.xml

Lines changed: 13 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/inspectionProfiles/Project_Default.xml

Lines changed: 41 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/libraries/libs.xml

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/misc.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/modules.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/.idea/vcs.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Interlude/aCis/VDSystem/Patch.diff

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
### Eclipse Workspace Patch 1.0
2+
#P aCis_gameserver
3+
diff --git .classpath .classpath
4+
index 169aae4..16e4bb0 100644
5+
--- .classpath
6+
+++ .classpath
7+
@@ -8,5 +8,6 @@
8+
</attributes>
9+
</classpathentry>
10+
<classpathentry kind="lib" path="lib/mariadb-java-client-2.6.1.jar"/>
11+
+ <classpathentry kind="lib" path="lib/VDSystem.jar"/>
12+
<classpathentry kind="output" path="bin"/>
13+
</classpath>
14+
diff --git java/net/sf/l2j/gameserver/GameServer.java java/net/sf/l2j/gameserver/GameServer.java
15+
index a60aaad..881ad50 100644
16+
--- java/net/sf/l2j/gameserver/GameServer.java
17+
+++ java/net/sf/l2j/gameserver/GameServer.java
18+
@@ -81,6 +81,7 @@
19+
import net.sf.l2j.gameserver.handler.SkillHandler;
20+
import net.sf.l2j.gameserver.handler.TargetHandler;
21+
import net.sf.l2j.gameserver.handler.UserCommandHandler;
22+
+import net.sf.l2j.gameserver.handler.VoicedCommandHandler;
23+
import net.sf.l2j.gameserver.idfactory.IdFactory;
24+
import net.sf.l2j.gameserver.model.World;
25+
import net.sf.l2j.gameserver.model.boat.BoatGiranTalking;
26+
@@ -103,6 +104,8 @@
27+
import net.sf.l2j.util.DeadLockDetector;
28+
import net.sf.l2j.util.IPv4Filter;
29+
30+
+import itopz.com.VDSystemManager;
31+
+
32+
public class GameServer
33+
{
34+
private static final CLogger LOGGER = new CLogger(GameServer.class.getName());
35+
@@ -270,6 +273,8 @@
36+
if (Config.ALLOW_FISH_CHAMPIONSHIP)
37+
FishingChampionshipManager.getInstance();
38+
39+
+ VDSystemManager.getInstance();
40+
+
41+
StringUtil.printSection("Handlers");
42+
LOGGER.info("Loaded {} admin command handlers.", AdminCommandHandler.getInstance().size());
43+
LOGGER.info("Loaded {} chat handlers.", ChatHandler.getInstance().size());
44+
@@ -277,6 +282,7 @@
45+
LOGGER.info("Loaded {} skill handlers.", SkillHandler.getInstance().size());
46+
LOGGER.info("Loaded {} target handlers.", TargetHandler.getInstance().size());
47+
LOGGER.info("Loaded {} user command handlers.", UserCommandHandler.getInstance().size());
48+
+ LOGGER.info("Loaded {} voice command handlers.", VoicedCommandHandler.getInstance().size());
49+
50+
StringUtil.printSection("System");
51+
Runtime.getRuntime().addShutdownHook(Shutdown.getInstance());
52+
diff --git java/net/sf/l2j/gameserver/handler/IVoicedCommandHandler.java java/net/sf/l2j/gameserver/handler/IVoicedCommandHandler.java
53+
new file mode 100644
54+
index 0000000..46838ef
55+
--- /dev/null
56+
+++ java/net/sf/l2j/gameserver/handler/IVoicedCommandHandler.java
57+
@@ -0,0 +1,10 @@
58+
+package net.sf.l2j.gameserver.handler;
59+
+
60+
+import net.sf.l2j.gameserver.model.actor.Player;
61+
+
62+
+public interface IVoicedCommandHandler
63+
+{
64+
+ public boolean useVoicedCommand(String command, Player activeChar);
65+
+
66+
+ public String[] getVoicedCommandList();
67+
+}
68+
\ No newline at end of file
69+
diff --git java/net/sf/l2j/gameserver/handler/VoicedCommandHandler.java java/net/sf/l2j/gameserver/handler/VoicedCommandHandler.java
70+
new file mode 100644
71+
index 0000000..8ed75c8
72+
--- /dev/null
73+
+++ java/net/sf/l2j/gameserver/handler/VoicedCommandHandler.java
74+
@@ -0,0 +1,41 @@
75+
+package net.sf.l2j.gameserver.handler;
76+
+
77+
+import java.util.Arrays;
78+
+import java.util.HashMap;
79+
+import java.util.Map;
80+
+
81+
+public class VoicedCommandHandler
82+
+{
83+
+ private final Map<Integer, IVoicedCommandHandler> VOICED_COMMANDS = new HashMap<>();
84+
+
85+
+ protected VoicedCommandHandler()
86+
+ {
87+
+ // registerVoicedCommand(new exampleCMD());
88+
+ }
89+
+
90+
+ public void registerVoicedCommand(IVoicedCommandHandler voicedCommand)
91+
+ {
92+
+ Arrays.stream(voicedCommand.getVoicedCommandList()).forEach(v -> VOICED_COMMANDS.put(v.intern().hashCode(), voicedCommand));
93+
+ }
94+
+
95+
+ public IVoicedCommandHandler getVoicedCommand(String voicedCommand)
96+
+ {
97+
+ return VOICED_COMMANDS.get(voicedCommand.hashCode());
98+
+ }
99+
+
100+
+ public int size()
101+
+ {
102+
+ return VOICED_COMMANDS.size();
103+
+ }
104+
+
105+
+ public static final VoicedCommandHandler getInstance()
106+
+ {
107+
+ return SingletonHolder.INSTANCE;
108+
+ }
109+
+
110+
+ private static final class SingletonHolder
111+
+ {
112+
+ private static final VoicedCommandHandler INSTANCE = new VoicedCommandHandler();
113+
+ }
114+
+
115+
+}
116+
\ No newline at end of file
117+
diff --git java/net/sf/l2j/gameserver/handler/chathandlers/ChatAll.java java/net/sf/l2j/gameserver/handler/chathandlers/ChatAll.java
118+
index 12c89b6..d344d90 100644
119+
--- java/net/sf/l2j/gameserver/handler/chathandlers/ChatAll.java
120+
+++ java/net/sf/l2j/gameserver/handler/chathandlers/ChatAll.java
121+
@@ -1,7 +1,10 @@
122+
package net.sf.l2j.gameserver.handler.chathandlers;
123+
124+
+import java.util.Optional;
125+
+
126+
import net.sf.l2j.gameserver.enums.SayType;
127+
import net.sf.l2j.gameserver.handler.IChatHandler;
128+
+import net.sf.l2j.gameserver.handler.VoicedCommandHandler;
129+
import net.sf.l2j.gameserver.model.actor.Player;
130+
import net.sf.l2j.gameserver.network.FloodProtectors;
131+
import net.sf.l2j.gameserver.network.FloodProtectors.Action;
132+
@@ -20,6 +23,11 @@
133+
if (!FloodProtectors.performAction(activeChar.getClient(), Action.GLOBAL_CHAT))
134+
return;
135+
136+
+ if (text.startsWith("."))
137+
+ {
138+
+ Optional.ofNullable(VoicedCommandHandler.getInstance().getVoicedCommand(text.substring(1).toLowerCase())).ifPresent(s -> s.useVoicedCommand(text, activeChar));
139+
+ return;
140+
+ }
141+
final CreatureSay cs = new CreatureSay(activeChar, type, text);
142+
for (Player player : activeChar.getKnownTypeInRadius(Player.class, 1250))
143+
player.sendPacket(cs);
144+
diff --git lib/VDSystem.jar lib/VDSystem.jar
145+
new file mode 100644
146+
index 0000000..30cc15e
147+
--- /dev/null
148+
+++ lib/VDSystem.jar
149+
Binary files differ

Interlude/aCis/VDSystem/VDSystem.iml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<module type="JAVA_MODULE" version="4">
3+
<component name="NewModuleRootManager" inherit-compiler-output="true">
4+
<exclude-output />
5+
<content url="file://$MODULE_DIR$">
6+
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
7+
</content>
8+
<orderEntry type="inheritedJdk" />
9+
<orderEntry type="sourceFolder" forTests="false" />
10+
<orderEntry type="library" name="libs" level="project" />
11+
</component>
12+
</module>
Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# ================================================================== #
2+
# -- ITOPZ Console VARS -- #
3+
# ================================================================== #
4+
# Console font, can be any font
5+
# Default: Roboto
6+
ConsoleFont = Roboto
7+
8+
# Console font size
9+
# Default: 12
10+
ConsoleFontSize = 12
11+
12+
# Console R,G,B background color
13+
# R default: 204
14+
ConsoleColorR = 204
15+
# G default: 238
16+
ConsoleColorG = 238
17+
# B default: 241
18+
ConsoleColorB = 241
19+
20+
# Console width size
21+
# Default: 400
22+
ConsoleWidth = 400
23+
24+
# Console height size
25+
# Default: 350
26+
ConsoleHeight = 350
27+
28+
# ================================================================== #
29+
# -- ITOPZ GLOBAL VOTE VARS -- #
30+
# ================================================================== #
31+
# Enable global reward
32+
# Default: True
33+
iTopZGlobalVoteReward = True
34+
35+
# Server ID
36+
# Default: 325339 (Test Server)
37+
ServerID = 325339
38+
39+
# Api key
40+
# Can be obtained at https://itopz.com/ after adding a server.
41+
# Default: DEMO (random values returned for test environments)
42+
ApiKey = DEMO
43+
44+
# Check Votes delay in seconds
45+
# Default: 1800 (30 minutes)
46+
CheckDelay = 1800
47+
48+
# Announce statistics on game
49+
# Default: True
50+
AnnounceStatistics = True
51+
52+
# Reward every XX votes
53+
# Default: 20
54+
VoteStep = 20
55+
56+
# Reward items
57+
# itemId (int), MIN(long), MAX(long), CHANCE(min 0, max 100)
58+
# example: itemId,MIN-MAX-CHANCE;itemId,MIN-MAX-CHANCE;
59+
# Default: 57,10000-99999-100;5575,500-1000-80;6622,1-5-20;
60+
GlobalRewards = 57,10000-99999-100;5575,500-1000-80;6622,1-5-20;
61+
62+
# ================================================================== #
63+
# -- ITOPZ Individual VOTE VARS -- #
64+
# ================================================================== #
65+
# Will also register a new command .itopz
66+
# Enable individual reward
67+
# Default: True
68+
IndividualReward = True
69+
70+
# Reward items
71+
# itemId (int), MIN(long), MAX(long), CHANCE(min 0, max 100)
72+
# example: itemId,MIN-MAX-CHANCE;itemId,MIN-MAX-CHANCE;
73+
# Default: 57,10000-99999-100;5575,500-1000-80;6622,1-5-20;
74+
IndividualRewards = 57,10000-99999-100;5575,500-1000-80;6622,1-5-20;
75+
76+
# ================================================================== #
77+
# -- ITOPZ Donate Manager VARS -- #
78+
# ================================================================== #
79+
# Enable Donation manager reward
80+
# Default: True
81+
DonateManager = True

Interlude/aCis/VDSystem/images/1.png

103 KB
Loading

Interlude/aCis/VDSystem/images/2.png

119 KB
Loading

Interlude/aCis/VDSystem/images/3.png

861 KB
Loading

Interlude/aCis/VDSystem/images/4.png

1 MB
Loading

Interlude/aCis/VDSystem/images/5.png

1.68 MB
Loading

Interlude/aCis/VDSystem/images/6.png

1.21 MB
Loading

Interlude/aCis/VDSystem/images/7.png

1.24 MB
Loading

0 commit comments

Comments
 (0)