Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: February 10th Beta Updates #1251

Merged
merged 20 commits into from
Feb 10, 2025
Merged
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
b310bcc
feat(content): Watch Tower quest (#1099)
Indio3 Feb 9, 2025
798a08b
fix(content): Fix issues with demon slayer authenticity (#1223)
Gregf36665 Feb 9, 2025
bbb9a14
fix(engine): send reboot timer on reconnect (#1233)
locked-chest Feb 9, 2025
4e405e7
fix(content): make cooking 1t faster (#1234)
tannerdino Feb 9, 2025
66be6e6
fix(engine): mod :: commands give text feedback (#1235)
locked-chest Feb 9, 2025
23df066
fix(content): change p_stopaction to p_walk(coord) for pvp freezes (#…
tannerdino Feb 9, 2025
ec6b404
feat(engine): search for nearby players using different algorithms (#…
ultraviolet-jordan Feb 9, 2025
a92b2ee
fix(engine): Follow pathing and walk triggers behave closer to pre-20…
mark-b5 Feb 9, 2025
08330a8
fix(engine): Reorganize interactions, movement, and run energy (#1240)
mark-b5 Feb 9, 2025
7696912
fix(engine): lineofsight and lineofwalk commands returning true for m…
ultraviolet-jordan Feb 9, 2025
7828690
fix(content): correct Sedridor typo (#1242)
Gregf36665 Feb 9, 2025
492d40b
fix(content): clear desert heat only when in desert (#1243)
Indio3 Feb 9, 2025
9a1ae0d
fix(content): thessalia dialogue, bunny_ears, scythe (#1203)
dhemms Feb 9, 2025
226e204
fix(engine): Obj command validation
Pazaz Feb 10, 2025
d76a605
feat(client): Use hotkey to show controls rather than icon (#1239)
seditionist Feb 10, 2025
0c3e330
fix(content): changes to chompy bird tracking, ranged xp reward (#1244)
Indio3 Feb 10, 2025
bc89ea3
fix(content): needle before chatplayer, fix mesanim (#1245)
Indio3 Feb 10, 2025
51088bf
fix(engine): I can't reach that! bug fix + remove unused code (#1249)
mark-b5 Feb 10, 2025
6b3a1ec
refactor(content): woodcutting sound, mes, and lvl 1 tree mechanics (…
tannerdino Feb 10, 2025
e2b6648
feat(engine): LoginServer abuse protection
Pazaz Feb 10, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix(engine): send reboot timer on reconnect (#1233)
Co-authored-by: sentientflare <179689881+sentientflare@users.noreply.github.com>
locked-chest and locked-chest authored Feb 9, 2025
commit bbb9a14f3b1fd817b7c5f22a5e92c05659d33a31
8 changes: 8 additions & 0 deletions src/engine/World.ts
Original file line number Diff line number Diff line change
@@ -80,7 +80,7 @@
import ScriptPointer from '#/engine/script/ScriptPointer.js';
import Isaac from '#/io/Isaac.js';
import LoggerEventType from '#/server/logger/LoggerEventType.js';
import MoveSpeed from '#/engine/entity/MoveSpeed.js';

Check warning on line 83 in src/engine/World.ts

GitHub Actions / verify

'MoveSpeed' is defined but never used. Allowed unused vars must match /^_/u
import ScriptVarType from '#/cache/config/ScriptVarType.js';

const priv = forge.pki.privateKeyFromPem(
@@ -963,7 +963,7 @@
try {
// if it throws then there was no available pid. otherwise guaranteed to not be -1.
pid = this.getNextPid(isClientConnected(player) ? player.client : null);
} catch (e) {

Check warning on line 966 in src/engine/World.ts

GitHub Actions / verify

'e' is defined but never used
// world full
if (isClientConnected(player)) {
player.addSessionLog(LoggerEventType.ENGINE, 'Tried to log in - world full');
@@ -1697,6 +1697,14 @@
}
}

get isPendingShutdown(): boolean {
return this.shutdownTicksRemaining > -1;
}

get shutdownTicksRemaining(): number {
return this.shutdownTick - this.currentTick;
}

broadcastMes(message: string): void {
for (const player of this.players) {
if (message.includes('\n')) {
@@ -1715,7 +1723,7 @@
}
}

onLoginMessage(msg: any) {

Check warning on line 1726 in src/engine/World.ts

GitHub Actions / verify

Unexpected any. Specify a different type
const { type } = msg;

if (type === 'player_login') {
@@ -1801,7 +1809,7 @@
}
}

onFriendMessage({ opcode, data }: { opcode: FriendsServerOpcodes, data: any }) {

Check warning on line 1812 in src/engine/World.ts

GitHub Actions / verify

Unexpected any. Specify a different type
try {
if (opcode === FriendsServerOpcodes.UPDATE_FRIENDLIST) {
const username37 = BigInt(data.username37);
6 changes: 6 additions & 0 deletions src/engine/entity/Player.ts
Original file line number Diff line number Diff line change
@@ -77,6 +77,7 @@
import LoggerEventType from '#/server/logger/LoggerEventType.js';
import InputTracking from '#/engine/entity/tracking/InputTracking.js';
import Visibility from './Visibility.js';
import UpdateRebootTimer from '#/network/server/model/UpdateRebootTimer.js';

const levelExperience = new Int32Array(99);

@@ -401,6 +402,11 @@
// force resyncing
// reload entity info (overkill? does the client have some logic around this?)
this.buildArea.clear(true);
// in case of pending update
if (World.isPendingShutdown) {
const ticksBeforeShutdown = World.shutdownTicksRemaining;
this.write(new UpdateRebootTimer(ticksBeforeShutdown));
}
// rebuild scene (rebuildnormal won't run if you're in the same zone!)
this.originX = -1;
this.originZ = -1;
@@ -1010,7 +1016,7 @@
return;
}

const opTrigger = this.getOpTrigger();

Check warning on line 1019 in src/engine/entity/Player.ts

GitHub Actions / verify

'opTrigger' is assigned a value but never used. Allowed unused vars must match /^_/u
this.nextTarget = null;

// opplayer3 is `Follow`
@@ -1201,7 +1207,7 @@
}
}

getInventoryFromListener(listener: any) {

Check warning on line 1210 in src/engine/entity/Player.ts

GitHub Actions / verify

Unexpected any. Specify a different type
if (listener.source === -1) {
return World.getInventory(listener.type);
} else {

Unchanged files with check annotations Beta

try {
child_process.execSync(`"${Environment.BUILD_JAVA_PATH}" -jar RuneScriptCompiler.jar`, { stdio: 'inherit' });
} catch (err) {

Check warning on line 54 in src/cache/PackAll.ts

GitHub Actions / verify

'err' is defined but never used
throw new Error('Failed to compile scripts.');
}
printWarning(message);
}
}
} catch (err: any) {

Check warning on line 158 in src/engine/script/ScriptRunner.ts

GitHub Actions / verify

Unexpected any. Specify a different type
// print the last opcode executed
if (state.pc >= 0 && state.pc < state.script.opcodes.length) {
const opcode = state.script.opcodes[state.pc];
AI_SPAWN = 166
}
namespace ServerTriggerType {

Check warning on line 164 in src/engine/script/ServerTriggerType.ts

GitHub Actions / verify

ES2015 module syntax is preferred over namespaces
export function toString(trigger: ServerTriggerType) {
return ServerTriggerType[trigger].toLowerCase();
}
import { PlayerQueueType, ScriptArgument } from '#/engine/entity/EntityQueueRequest.js';
import { PlayerTimerType } from '#/engine/entity/EntityTimer.js';
import { isBufferFull, isClientConnected } from '#/engine/entity/NetworkPlayer.js';

Check warning on line 18 in src/engine/script/handlers/PlayerOps.ts

GitHub Actions / verify

'isClientConnected' is defined but never used. Allowed unused vars must match /^_/u
import { CoordGrid } from '#/engine/CoordGrid.js';
import CameraInfo from '#/engine/entity/CameraInfo.js';
import Interaction from '#/engine/entity/Interaction.js';