1
0
mirror of synced 2025-01-19 08:37:26 +01:00

fix a lot of terminal stuff, scrach is stil broken

This commit is contained in:
doomertheboomer 2022-07-14 18:00:20 +07:00
parent 1105d96e6e
commit 44e9d44bb9
3 changed files with 3706 additions and 18 deletions

3652
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@ -22,24 +22,6 @@ export default class GameModule extends Module {
})
//terminal specific
app.post('/method/start_transfer', (req, res) => {
let msg = {
error: wm.wm.protobuf.ErrorCode.ERR_SUCCESS,
userId: 0,
}
let resp = wm.wm.protobuf.StartTransferResponse.encode(msg);
let end = resp.finish();
let r = res
.header('Server', 'v388 wangan')
.header('Content-Type', 'application/x-protobuf; revision=8053')
.header('Content-Length', end.length.toString())
.status(200);
r.send(Buffer.from(end));
})
//banapass loading
app.post('/method/load_terminal_information', (req, res) => {
let msg = {
error: wm.wm.protobuf.ErrorCode.ERR_SUCCESS,
@ -61,6 +43,58 @@ export default class GameModule extends Module {
r.send(Buffer.from(end));
})
app.post('/method/load_scratch_information', (req, res) => {
let msg = {
error: wm.wm.protobuf.ErrorCode.ERR_SUCCESS,
currentSheet: 21,
numOfScratched: 0,
}
let resp = wm.wm.protobuf.LoadScratchInformationResponse.encode(msg);
let end = resp.finish();
let r = res
.header('Server', 'v388 wangan')
.header('Content-Type', 'application/x-protobuf; revision=8053')
.header('Content-Length', end.length.toString())
.status(200);
r.send(Buffer.from(end));
})
app.post('/method/update_car', (req, res) => {
let msg = {
error: wm.wm.protobuf.ErrorCode.ERR_SUCCESS,
}
let resp = wm.wm.protobuf.UpdateCarResponse.encode(msg);
let end = resp.finish();
let r = res
.header('Server', 'v388 wangan')
.header('Content-Type', 'application/x-protobuf; revision=8053')
.header('Content-Length', end.length.toString())
.status(200);
r.send(Buffer.from(end));
})
//banapass loading
app.post('/method/start_transfer', (req, res) => {
let msg = {
error: wm.wm.protobuf.ErrorCode.ERR_SUCCESS,
userId: 0,
}
let resp = wm.wm.protobuf.StartTransferResponse.encode(msg);
let end = resp.finish();
let r = res
.header('Server', 'v388 wangan')
.header('Content-Type', 'application/x-protobuf; revision=8053')
.header('Content-Length', end.length.toString())
.status(200);
r.send(Buffer.from(end));
})
app.post('/method/load_user', (req, res) => {
//everything after this should be replaced with values from a database, but thats above my pay grade :P
let msg = {

2
start.bat Normal file
View File

@ -0,0 +1,2 @@
yarn dev
pause