Skip to content

Commit

Permalink
Beta 1.7!!! (#126)
Browse files Browse the repository at this point in the history
* Rebase (not sure if this is the right term, but pulled origin/main and resetted to match commit history)

* Dizzywing Dispatch Implementation (#122)

* Various fixes related to chat

* Even more fixes-

* Add changelog

* Update changelog, had forgotten something

* Fix teleport bug

* Implementation of Kino Games (#123)

* Fixes i forgot to push

* Fix another bug

* Hotfixes (#124)

* Switch to EmuFeral domains since AerialWorks servers are sunsetting

* Update connective dependencies

* Update readme

* Fix example module setup scripts

* Update changelog

* Staff name colors

* Liststaff command, add save colors

* Changes to maintenance mode

* Further work

* Update changelog

* Update changelog

* Improve staff list command

* Make staff list command player-usable

* Remove newline

* Rename version to beta 1.7

* Update changelog

* Potentially patched the favorite player join popup bug

* That patch didnt work

* New command

* Fix inspirations

* Fix spawning freezing up

* Improve network code

* Add a update build script that doesnt immediately upload too

---------

Co-authored-by: Bobby Tables <[email protected]>
  • Loading branch information
SkySwimmer and bobby-tables2 authored Oct 1, 2023
1 parent d6f1af3 commit a5fe850
Show file tree
Hide file tree
Showing 81 changed files with 5,327 additions and 1,167 deletions.
6 changes: 3 additions & 3 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
*.reg -crlf
*.bat -crlf
*.sh -crlf
*.bash -crlf
gradlew -crlf
*.sh -lf
*.bash -lf
gradlew -lf
6 changes: 5 additions & 1 deletion .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@ jobs:
distribution: 'temurin'
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Create dependency folder
run: mkdir deps
- name: Download connective
run: git clone https://github.com/SkySwimmer/connective-http deps/connective-http
- name: Build with Gradle
uses: gradle/gradle-build-action@v2.4.2
uses: gradle/gradle-build-action@v2
with:
arguments: build
- name: Publish build artifact
Expand Down
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
build/
.gradle

# Dependencies
deps/

# Eclipse
bin/
.settings/
Expand Down Expand Up @@ -31,4 +34,4 @@ update.list
updater.jar

# macOS
**/.DS_Store
**/.DS_Store
1 change: 1 addition & 0 deletions Centuria.launch
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.jdt.launching.localJavaApplication">
<booleanAttribute key="org.eclipse.debug.core.ATTR_FORCE_SYSTEM_CONSOLE_ENCODING" value="false"/>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
<listEntry value="/Centuria/src/main/java/org/asf/centuria/Centuria.java"/>
</listAttribute>
Expand Down
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ To build Centuria you will need to have Java 17 JDK installed. Centuria is build
## Building on Windows
On windows, run the following commands in cmd or powershell::

Download dependencies:
```powershell
mkdir deps
git clone https://github.com/SkySwimmer/connective-http deps/connective-http
```

Set up a development environment (optional):
```powershell
.\gradlew eclipse
Expand All @@ -27,6 +33,12 @@ Configure permissions:
chmod +x gradlew
```

Download dependencies:
```bash
mkdir deps
git clone https://github.com/SkySwimmer/connective-http deps/connective-http
```

Set up a development environment (optional):
```bash
./gradlew eclipse createEclipseLaunches
Expand All @@ -43,7 +55,7 @@ After building, you can find the compiled server in `build/Installations`, you c
<br/>

## Note about self-hosted servers
Due to the lack of a easy-to-use launcher, hosting a server yourself may prove difficult. You will need to edit your client's `Fer.al_Data/sharedassets1.assets` and swap out the server endpoints, however this can be tricky, you may run into string length issues. You can obtain a localhost sharedassets patch from the [AerialWorks Centuria Server](https://aerialworks.ddns.net/emuferal/sharedassets1.assets).
Due to the lack of a easy-to-use launcher, hosting a server yourself may prove difficult. You will need to edit your client's `Fer.al_Data/sharedassets1.assets` and swap out the server endpoints, however this can be tricky, you may run into string length issues. (a guide will be made in the near-future)

<br/>

Expand Down
7 changes: 7 additions & 0 deletions Requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Centuria requires the following projects:
- connective-http (2023 rewrite and above): https://github.com/SkySwimmer/connective-http

Commands to set up dependencies:
- Connective:
mkdir deps
git clone https://github.com/SkySwimmer/connective-http deps/connective-http
10 changes: 5 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ plugins {
id 'maven-publish'
}

version = "1.6.4.B3"
version = "b1.7"
group = "org.asf.centuria"

sourceCompatibility = '1.17'
Expand All @@ -17,7 +17,7 @@ apply plugin: 'idea'
repositories {
mavenCentral()
flatDir {
dirs 'libraries', 'fluid'
dirs 'fluid'
}
}

Expand Down Expand Up @@ -60,8 +60,7 @@ artifacts {
}

dependencies {
implementation name: "ConnectiveHTTP"
implementation name: "RatsMemory"
implementation project(":deps:connective-http")

implementation group: 'org.asf.cyan', name: 'Fluid', version: '1.0.0.A33'

Expand All @@ -71,8 +70,9 @@ dependencies {
implementation 'org.ow2.asm:asm:9.1'
implementation 'org.ow2.asm:asm-tree:9.1'
implementation 'org.ow2.asm:asm-commons:9.1'

implementation group: 'com.google.code.gson', name: 'gson', version: '2.9.0'
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-xml', version: '2.13.3'
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-xml', version: '2.15.2'

implementation group: 'javax.activation', name: 'activation', version: '1.1.1'

Expand Down
78 changes: 78 additions & 0 deletions buildupdate.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
#!/bin/bash

function copyUpdateData() {
version="$1"
channel="$2"

# Create directory
mkdir -p "build/updatedata/emuferal.ddns.net/httpdocs/$channel" || exit 1

# Copy files
function copyData() {
for file in $1/* ; do
pref=$2
targetf="${file:${#pref}}"
if [ -f "$file" ]; then
dir="$(dirname "build/updatedata/emuferal.ddns.net/httpdocs/$channel/${version}/${targetf}")"
if [ ! -d "$dir" ]; then
mkdir -p "$dir" || exit 1
fi
cp -rfv "$file" "build/updatedata/emuferal.ddns.net/httpdocs/$channel/${version}/${targetf}"
fi
if [ "$?" != "0" ]; then
echo Build failure!
exit 1
fi
if [ -d "$file" ]; then
copyData "$file" "$2"
fi
done
}

copyData build/update build/update/
echo -n "$version" > "build/updatedata/emuferal.ddns.net/httpdocs/$channel/update.info"

source version.info
}

# Current channel
echo Preparing...
source version.info
rm -rf build/updatedata
rm -rf build/update
echo
echo
echo Centuria Update Builder
echo Version: $version
echo Version type: $channel
echo
echo
read -p "Are you sure you want to build this version's update files? [Y/n] " prompt

if [ "$prompt" != "y" ] && [ "$prompt" != "Y" ]; then
exit
fi

echo Building centuria...
./gradlew build updateData || exit $?
echo

echo Copying data...
copyUpdateData "$version" "$channel"

# Other channels
if [ "$channel" == "beta" ]; then
copyUpdateData "$version" alpha
fi
if [ "$channel" == "prerelease" ]; then
copyUpdateData "$version" alpha
copyUpdateData "$version" beta
fi
if [ "$channel" == "release" ]; then
copyUpdateData "$version" alpha
copyUpdateData "$version" beta
copyUpdateData "$version" prerelease
fi

echo
echo Build completed.
48 changes: 48 additions & 0 deletions changelogs/b1.7
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
New features in 1.7:
- Implemented Dizzywing Dispatch partially (credits to animal animalson)
- Implemented Kino minigames (credits to animal animalson, unclear if its fully in place, needs testing)
- Saves can now have different colors, you will be able to tell if someone is in experience mode or creative by the name colors
- Staff now have different name colors and a tag before their name showing their rank

Fixes in 1.7:
- Fixed account unpair issues with account deletion
- Fixed loot spawning locking up sometimes which caused loot not to respawn every now and then
- Fixed True Friendship inspiration and some others not being given to the player
- Fix dms and gcs having ghost entries if accounts get deleted (chat has been fixed)
- Fixed levels not being refreshed on logout and save switch
- Fixed server not fully teleporting players
- Fixed invalid unread counts
- Fixed player name changes not synchronizing immediately
- Corrected time bonus of Do or Dye level 104
- Patched account registration

Changes in 1.7:
- FTL (modloader) has been overhauled
- Made it that modules can override existing network packets
- Updated Connective libraries, this will help with stability
- Updated the FeralTweaks server module data processor so that it doesnt require authorization for chart patch downloads
- Made it that maintenance mode doesnt automatically shut the server down when everyone is offline
- Maintenance mode no longer allows staff login apart from admins
- FeralTweaks server code has been overhaulled to be more clean and easier to navigate through

Command changes:
- The 'toggleghostmode' command no longer requires admin clearance
- New staff command: startmaintenancetimer: command to schedule server maintenance (minutes)
- New staff command: schedulemaintenance: command to schedule server maintenance (date/time)
- New staff command: cancelmaintenance: cancels scheduled server maintenance
- new staff command: stopserver: stops the server (uses a update shutdown message without feraltweaks, but uses a custom message with feraltweaks)
- New player-usable command: stafflist: lists all staff users on the server (with online status)

Modloader changes:
- Removed patches that caused the game to lag
- Overhauled inner workings of feraltweaks making it much more stable
- Implemented asset injection and chart injection for mods
- Implemented mod packages and packaging system
- Implemented a mod networking framework
- Fixed issues preventing multiple of the same client from starting
- Added support for command line arguments
- Logging overhaul

Launcher fixes:
- Fixed issues where on some systems the modloader could freeze
- Fixed issues with the start scripts, making them more compatible with installers
3 changes: 1 addition & 2 deletions examplemodule/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ ext.buildyear = cal.get(Calendar.YEAR).toString();

repositories {
mavenCentral()
maven { name = "AerialWorks"; url = "https://aerialworks.ddns.net/maven" }
flatDir {
dirs 'libraries'
}
Expand All @@ -59,7 +58,7 @@ dependencies {
testImplementation group: 'junit', name: 'junit', version: '4.13.2'

implementation name: "Centuria"
implementation name: "ConnectiveHTTP"
implementation name: "connective-http"
}

createEclipseLaunches {
Expand Down
4 changes: 2 additions & 2 deletions examplemodule/createlocalserver.bat
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ echo Building...
goto execute

:execute
if NOT EXIST deps mkdir deps
git clone https://github.com/SkySwimmer/connective-http deps/connective-http
cmd /c java -cp gradle/wrapper/gradle-wrapper.jar org.gradle.wrapper.GradleWrapperMain installation

if NOT EXIST "%dir%\server" mkdir "%dir%\server"

robocopy /E /NFL /NDL /NJH /NJS /nc /ns /np build/Installations "%dir%\server"
for /R libraries %%f in (*-javadoc.jar) do copy /Y %%f "%dir%\server\libs" >NUL
for /R libraries %%f in (*-sources.jar) do copy /Y %%f "%dir%\server\libs" >NUL

if NOT EXIST "%dir%\libraries" mkdir "%dir%\libraries"
copy /Y build\Installations\Centuria.jar "%dir%\libraries" >NUL
Expand Down
4 changes: 2 additions & 2 deletions examplemodule/createlocalserver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ function exitmeth() {

function execute() {
chmod +x gradlew
mkdir deps
git clone https://github.com/SkySwimmer/connective-http deps/connective-http
./gradlew installation || return $?
if [ ! -d "$dir/server" ]; then
mkdir "$dir/server"
fi
cp -rf "build/Installations/." "$dir/server"
cp -rf "libraries/"*-javadoc.jar "$dir/server/libs"
cp -rf "libraries/"*-sources.jar "$dir/server/libs"
cp "build/Installations/Centuria.jar" "$dir/server/libs"

if [ ! -d "$dir/libraries" ]; then
Expand Down
Binary file removed libraries/ConnectiveHTTP-javadoc.jar
Binary file not shown.
Binary file removed libraries/ConnectiveHTTP-sources.jar
Binary file not shown.
Binary file removed libraries/ConnectiveHTTP.jar
Binary file not shown.
Binary file removed libraries/RatsMemory.jar
Binary file not shown.
Binary file removed libraries/log4j-api.jar
Binary file not shown.
Binary file removed libraries/log4j-core.jar
Binary file not shown.
1 change: 1 addition & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
rootProject.name = 'Centuria'
include("deps:connective-http")
Loading

0 comments on commit a5fe850

Please sign in to comment.