mirror of
https://github.com/redstrate/Kawari.git
synced 2025-05-12 14:47:46 +00:00
"Implement" the Unending Journey
Apparently there's a scene that's super easy to use, that omniously says "You cannot consult The Unending Journey at this time". That's cool, though.
This commit is contained in:
parent
515ec59d92
commit
ed44de8956
4 changed files with 12 additions and 84 deletions
1
USAGE.md
1
USAGE.md
|
@ -79,7 +79,6 @@ This feature is still a work-in-progress, and not all data is imported yet.
|
||||||
These special debug commands start with `!` and are custom to Kawari.
|
These special debug commands start with `!` and are custom to Kawari.
|
||||||
|
|
||||||
* `!setpos <x> <y> <z>`: Teleport to the specified location
|
* `!setpos <x> <y> <z>`: Teleport to the specified location
|
||||||
* `!spawnplayer`: Spawn another player for debugging, not known to work at the moment
|
|
||||||
* `!spawnnpc`: Spawn a NPC for debugging
|
* `!spawnnpc`: Spawn a NPC for debugging
|
||||||
* `!spawnmonster`: Spawn a monster for debugging
|
* `!spawnmonster`: Spawn a monster for debugging
|
||||||
* `!playscene <id>`: Plays an event. Only some events are supported for now:
|
* `!playscene <id>`: Plays an event. Only some events are supported for now:
|
||||||
|
|
|
@ -26,6 +26,7 @@ registerAction(9, "actions/FastBlade.lua")
|
||||||
registerAction(6221, "items/Fantasia.lua")
|
registerAction(6221, "items/Fantasia.lua")
|
||||||
|
|
||||||
-- Events
|
-- Events
|
||||||
|
registerEvent(721028, "tosort/UnendingJourney.lua")
|
||||||
registerEvent(131079, "warp/WarpInnLimsaLominsa.lua")
|
registerEvent(131079, "warp/WarpInnLimsaLominsa.lua")
|
||||||
registerEvent(131080, "warp/WarpInnGridania.lua")
|
registerEvent(131080, "warp/WarpInnGridania.lua")
|
||||||
registerEvent(131081, "warp/WarpInnUldah.lua")
|
registerEvent(131081, "warp/WarpInnUldah.lua")
|
||||||
|
@ -45,3 +46,4 @@ registerEvent(1245187, "opening/OpeningUldah.lua")
|
||||||
-- Commands
|
-- Commands
|
||||||
registerCommand("setpos", "commands/debug/SetPos.lua")
|
registerCommand("setpos", "commands/debug/SetPos.lua")
|
||||||
registerCommand("classjob", "commands/debug/ClassJob.lua")
|
registerCommand("classjob", "commands/debug/ClassJob.lua")
|
||||||
|
registerCommand("setspeed", "commands/debug/SetSpeed.lua")
|
||||||
|
|
10
resources/scripts/tosort/UnendingJourney.lua
Normal file
10
resources/scripts/tosort/UnendingJourney.lua
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
-- TODO: actually implement this menu
|
||||||
|
|
||||||
|
function onTalk(target, player)
|
||||||
|
-- you cannot consult, which is good because we don't know how to implement this anyway
|
||||||
|
player:play_scene(target, EVENT_ID, 00000, 8192, 0)
|
||||||
|
end
|
||||||
|
|
||||||
|
function onReturn(scene, results, player)
|
||||||
|
player:finish_event(EVENT_ID)
|
||||||
|
end
|
|
@ -54,89 +54,6 @@ impl ChatHandler {
|
||||||
|
|
||||||
let parts: Vec<&str> = chat_message.message.split(' ').collect();
|
let parts: Vec<&str> = chat_message.message.split(' ').collect();
|
||||||
match parts[0] {
|
match parts[0] {
|
||||||
"!spawnplayer" => {
|
|
||||||
let config = get_config();
|
|
||||||
|
|
||||||
// send player spawn
|
|
||||||
{
|
|
||||||
let ipc = ServerZoneIpcSegment {
|
|
||||||
unk1: 20,
|
|
||||||
unk2: 0,
|
|
||||||
op_code: ServerZoneIpcType::PlayerSpawn,
|
|
||||||
option: 0,
|
|
||||||
timestamp: timestamp_secs(),
|
|
||||||
data: ServerZoneIpcData::PlayerSpawn(PlayerSpawn {
|
|
||||||
account_id: 1000000,
|
|
||||||
content_id: 1000000,
|
|
||||||
current_world_id: config.world.world_id,
|
|
||||||
home_world_id: config.world.world_id,
|
|
||||||
common: CommonSpawn {
|
|
||||||
class_job: 35,
|
|
||||||
name: "Test Actor".to_string(),
|
|
||||||
hp_curr: 250,
|
|
||||||
hp_max: 250,
|
|
||||||
mp_curr: 10000,
|
|
||||||
mp_max: 10000,
|
|
||||||
level: 5,
|
|
||||||
object_kind: ObjectKind::Player(PlayerSubKind::Player),
|
|
||||||
spawn_index: connection.get_free_spawn_index(),
|
|
||||||
look: CUSTOMIZE_DATA,
|
|
||||||
display_flags: DisplayFlag::INVISIBLE
|
|
||||||
| DisplayFlag::HIDE_HEAD
|
|
||||||
| DisplayFlag::UNK,
|
|
||||||
models: [
|
|
||||||
0, // head
|
|
||||||
89, // body
|
|
||||||
89, // hands
|
|
||||||
89, // legs
|
|
||||||
89, // feet
|
|
||||||
0, // ears
|
|
||||||
0, // neck
|
|
||||||
0, // wrists
|
|
||||||
0, // left finger
|
|
||||||
0, // right finger
|
|
||||||
],
|
|
||||||
pos: connection.player_data.position,
|
|
||||||
..Default::default()
|
|
||||||
},
|
|
||||||
..Default::default()
|
|
||||||
}),
|
|
||||||
};
|
|
||||||
|
|
||||||
connection
|
|
||||||
.send_segment(PacketSegment {
|
|
||||||
source_actor: 0x106ad804,
|
|
||||||
target_actor: connection.player_data.actor_id,
|
|
||||||
segment_type: SegmentType::Ipc,
|
|
||||||
data: SegmentData::Ipc { data: ipc },
|
|
||||||
})
|
|
||||||
.await;
|
|
||||||
}
|
|
||||||
|
|
||||||
// zone in
|
|
||||||
{
|
|
||||||
let ipc = ServerZoneIpcSegment {
|
|
||||||
op_code: ServerZoneIpcType::ActorControl,
|
|
||||||
timestamp: timestamp_secs(),
|
|
||||||
data: ServerZoneIpcData::ActorControl(ActorControl {
|
|
||||||
category: ActorControlCategory::ZoneIn {
|
|
||||||
warp_finish_anim: 0x0,
|
|
||||||
raise_anim: 0x0,
|
|
||||||
},
|
|
||||||
}),
|
|
||||||
..Default::default()
|
|
||||||
};
|
|
||||||
|
|
||||||
connection
|
|
||||||
.send_segment(PacketSegment {
|
|
||||||
source_actor: 0x106ad804,
|
|
||||||
target_actor: connection.player_data.actor_id,
|
|
||||||
segment_type: SegmentType::Ipc,
|
|
||||||
data: SegmentData::Ipc { data: ipc },
|
|
||||||
})
|
|
||||||
.await;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
"!spawnnpc" => {
|
"!spawnnpc" => {
|
||||||
let ipc = ServerZoneIpcSegment {
|
let ipc = ServerZoneIpcSegment {
|
||||||
op_code: ServerZoneIpcType::NpcSpawn,
|
op_code: ServerZoneIpcType::NpcSpawn,
|
||||||
|
|
Loading…
Add table
Reference in a new issue