Skip to content

Commit

Permalink
beta
Browse files Browse the repository at this point in the history
  • Loading branch information
Manticore-007 committed Jul 7, 2024
1 parent 8b05472 commit f299fec
Show file tree
Hide file tree
Showing 7 changed files with 360 additions and 297 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "openrct2-peep-editor",
"author": "Manticore-007",
"license": "MIT",
"version": "24.7.6",
"version": "24.7.7",
"description": "",
"main": "app.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ const config = {
wrap_iife: true,
preamble: "// Get the latest version: https://github.com/Manticore-007/OpenRCT2-PeepEditor",

beautify: true,
beautify: false,
},
mangle: {
properties: {
Expand Down
2 changes: 2 additions & 0 deletions src/actions/initActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { PeepColourArgs, colourPeepExecute } from "./peepColour";
import { PeepMoveArgs, movePeepExecute } from "./peepMover";
import { PeepNameArgs, namePeepExecute } from "./peepNamer";
import { PeepRemoveArgs, removePeepExecute } from "./peepRemover";
import { PeepRotateArgs, peepRotateExecute } from "./peepRotater";
import { PeepSpeedArgs, peepSpeedExecute } from "./peepSpeed";
import { queryPermissionCheck } from "./permissions";
import { StaffCostumeArgs, staffCostumeExecute } from "./staffSetCostume";
Expand All @@ -38,4 +39,5 @@ context.registerAction<GuestNauseaArgs>("pe-guestnausea", (args) => queryPermiss
context.registerAction<GuestToiletArgs>("pe-guesttoilet", (args) => queryPermissionCheck(args), (args) => guestToiletExecute(args.args));
context.registerAction<GuestMassArgs>("pe-guestmass", (args) => queryPermissionCheck(args), (args) => guestMassExecute(args.args));
context.registerAction<GuestItemRemoveArgs>("pe-guestitemremove", (args) => queryPermissionCheck(args), (args) => guestItemRemoveExecute(args.args));
context.registerAction<PeepRotateArgs>("pe-peeprotate", (args) => queryPermissionCheck(args), (args) => peepRotateExecute(args.args));
}
26 changes: 26 additions & 0 deletions src/actions/peepRotater.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import { model } from "../viewmodel/peepViewModel";

export interface PeepRotateArgs {
}

export function peepRotateExecute(args: PeepRotateArgs): GameActionResult
{
args;
const allGuests = model._allGuests.get();
const numDirections = 4
if (allGuests !== undefined) {
const firstPeep = <Guest>allGuests[0];
const direction = firstPeep.direction;
allGuests.forEach(entity => {
const peep = <Guest|Staff>entity;
if (peep.direction !== direction) {peep.direction = direction};
peep.direction = (peep.direction + 1) % numDirections;
})
}

return {};
}

export function peepRotateExecuteArgs(): PeepRotateArgs{
return {};
}
20 changes: 0 additions & 20 deletions src/helpers/rides.ts

This file was deleted.

Loading

0 comments on commit f299fec

Please sign in to comment.