Commit graph

314 commits

Author SHA1 Message Date
Aaron van Geffen
805c8e2a11
Plugin: allow scripts to specify tab colour maps (#23583) 2025-01-13 23:47:30 +01:00
Aaron van Geffen
fa06a49302
Update copyright year to 2025 (#23514) 2024-12-31 20:30:04 +01:00
AT41
6e7b489304
Added additional stats to Plugin interface
Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2024-10-03 11:23:50 +00:00
kendfrey
307523610e
Add Park.generateGuest() to plugin API (#22883)
Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2024-10-02 06:49:43 -03:00
Duncan
e157a843f0
Large scenery object tiles for scripting (#22842)
Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2024-10-01 21:02:46 -03:00
Harry Hopkinson
89637013e8
Fix #21507: Expose suggestedGuestMaximum via hook (#21521) 2024-09-11 21:17:26 -03:00
Guy Sviry
332df0f1db
expose Vehicle.spin_sprite to Car scripting (#22392)
* expose spinSprite to Car scripting

---------

Co-authored-by: Guy Sviry <guy@axissecurity.com>
2024-08-07 18:13:33 +01:00
Guy Sviry
30a555d3c2
Expose vehicle.trackType to scripting (#22272)
Co-authored-by: Guy Sviry <guy@axissecurity.com>
2024-07-25 17:27:15 -03:00
Arnold Zhou
a749698566
[Plugin API] Feat: Expose staff statistics (#22184) 2024-07-24 20:10:34 -03:00
Stephan Spengler
ba779ac64c
Change ToolEventArgs.mapCoords from CoordsXYZ to CoordsXY
Testing showed that the event returns CoordsXY instead of CoordsXYZ. The code can be traced back to InteractionInfo.Loc (Viewport.h), which is CoordsXY.
2024-07-24 16:42:02 +02:00
Arnold Zhou
2da5ed6517
[Plugin API] Fix: add missing hook types, order & style (#22134) 2024-07-23 07:49:57 -03:00
Arnold Zhou
376e749a70
Allow plugins to focus on textboxes in custom windows (#22213) 2024-07-08 14:49:15 +02:00
Arnold Zhou
aa11d8ddfe
Expose ride satisfaction to plugin api (#22172) 2024-07-08 10:53:14 +02:00
Aaron van Geffen
f2c266d310 Allow scripts to manipulate peep directions 2024-07-05 15:46:03 +02:00
Aaron van Geffen
ed6bde7d56 Introduce peep flags for static positions and animations 2024-06-29 14:42:09 +02:00
spacek531
4e72d580f8
Allow non-networked plug-ins to set pause state directly 2024-06-25 11:36:01 +02:00
Arnold Zhou
a0f5d09408
Expose monthly expenditure history to plug-in API 2024-06-23 22:49:49 +02:00
Stephan Spengler
73043106ed
[Plugin] Add banner index to banner creation result 2024-05-29 22:35:35 +02:00
spacek531
94750f4e34
Add plugin API to VehicleCrashedParticle 2024-05-29 12:32:41 +02:00
Arnold Zhou
01319ff352
Expose guest's favourite ride (ID) to plugin API 2024-05-27 15:18:02 +02:00
Harry Hopkinson
68f2b0f207
Close #18829: Add g1 icons to scripting 2024-05-26 21:48:42 +02:00
Stephan Spengler
7315b3bdbf
Adjust API documentation to changes from #22013 2024-05-22 23:47:21 +02:00
Ted John
abc67f09e6
Add ability to shift map 2024-05-18 21:10:52 +02:00
Aaron van Geffen
893392d987
Scripting: allow precise and safe control of peep animations 2024-05-05 21:09:41 +00:00
Aaron van Geffen
831c7651bb
Scripting: tailor costume assignment to each staff type
In order to transition staff costumes to objects, we must further disentangle staff from regular peeps. This has many advantages, such as making custom entertainers or even handymen costumes. However, this means putting some restrictions on what costumes can be assigned to staff in the mean while.

We are aware of plug-ins allowing staff to be decorated like normal peeps, though, e.g. using @Manticore-007's Peep Editor. Splitting staff from peeps will mean breaking such functionality. We can do our very best to reverting 'invalid' staff to their normal outfits instead of them outright disappearing. However, in the mean time, we should disallow peep costumes from being assigned to staff to prevent further disappointment down the line.

Once we get to actually adding custom staff costumes, I plan to add a new plug-in API to get available costumes for a particular staff type. This would apply to entertainers, but also other staff types. This should make it easier for plug-in authors to tap into custom costumes in the future.
2024-05-05 22:41:52 +02:00
Katherine Norton
cd528665e6
Expose whether the game is paused to the plugin API 2024-05-03 15:59:57 +00:00
Aaron van Geffen
d536f9bce0
Revert "Add owner property to tile elements for scripting"
This reverts commit b4376ab590.
2024-04-12 21:58:45 +02:00
Stephan Spengler
2913a0686a
Add banner properties to plugin API for large scenery, walls and banners 2024-03-26 11:42:09 +00:00
Stephan Spengler
304ce22756
Improve research documentation for plugin API 2024-03-21 14:11:52 +01:00
Stephan Spengler
01248c26a4
Improve API documentation: use Direction type in FootpathElement
Change type of slopeDirection and queueBannerDirection of footpaths to Direction in openrct2.d.ts
2024-03-06 18:22:50 +01:00
Alex Parisi
efb6d48c4c
Add plugin API to get registered plugin metadata (#20709)
* Added API for getAllPlugins

Added functionality to the Scripting API to allow Contexts to return a list of all registered plugins.

* Fixed naming conventions, returning list of authors

Changed function names to follow get/set convention. Removed unnecessary copies of shared pointers, now using auto instead. Changed the functionality to return an array of authors instead of a string.

* Added changelog entry

Also added myself to list of contributors

* Moved all functionality to ScPlugin

Created a ScPlugin class and moved the current getPlugins functionality there.

* Changed from method to property

Function names now match the get/set convention for properties. Also did some code cleanup.

* Update copyright

* Bump plugin version

---------

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2024-02-16 05:53:48 -03:00
Katherine Norton
0450435377
Add Plugin API for managing a guest's items (#21062)
* Add API for guest items in openrct2.d.ts

* Create GuestItem interfaces

* Set fields to readonly and add documentation

* Implement getting items array

* Implement checking if a guest has an item

* Implement removing items from guests

* Implement giving a guest an item

* Re-merge GuestItemType with FoodDrinkType

* Add more data validation for the EnumMaps

* Update versioning and changelog

* Add some errors to the give_item method

* Bump network version

* Update VoucherType to if/else

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>

* Add static_assert to ScGuest.hpp

---------

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2024-01-20 11:51:23 -03:00
Stephan Spengler
e8a7bc43b3
Plugin documentation: Added missing field to SmallSceneryElement 2024-01-15 12:42:40 +01:00
Matt
c137d20a0b
Merge pull request #21163 from fidwell/plugin-api-SmallSceneryPlaceArgs
Plugin documentation: Added missing required field to SmallSceneryPlaceArgs
2024-01-06 20:02:45 +02:00
Andrew
2768716238 Added missing required field to SmallSceneryPlaceArgs 2024-01-06 11:28:00 -05:00
James103
1d8dc111f1
Replace 2023 with 2024 in copyright headers (#21139)
Replace all instances of the year 2023 with 2024 in all copyright headers
2024-01-01 12:52:28 +01:00
ζeh Matt
b4376ab590
Add owner property to tile elements for scripting 2023-10-08 02:30:43 +03:00
Andrew
e17bca3b53
Made setting the game speed a game action (#20825)
* Bare minimum for a game action

* Changelog entry

* Fixed formatting

* Consistent capitalization

* Committed wrong file

* Removing redundant toolbar invalidations

* Bump network version; remove redundant qualifier

* Fixed crash on starting server
2023-10-04 16:13:40 +01:00
Crazycolbster
a7881a5046
Fixed typo in openrct2.d.ts, ScenarioObjectiveType (#20592) 2023-07-10 22:14:30 +01:00
Matthias Moninger
3edb044685
Merge pull request #20100 from IntelOrca/plugin/object-manager
Add plugin APIs for the object manager
2023-06-26 02:26:13 +03:00
AuraSpecs
870c78001e
Add new roller coaster ride colour presets (#20119)
* Fix G2 order and format

PR #19446 did not follow the correct G2 order so this is fixing that.

Also adds the added icons to the [Plugin] chart as should when adding icons to G2.

* Add colour documentation

* Joker's Jinx colour

For the LIM Launched, based on Premier rides LIM RC.

* Poltergeist colour

Based on a Premier rides LIM RC

* Flight of Fear colour

* Add Mega-Lite colour scheme

* Add colours for Vertical Drop RC

* Add two HyperCoaster presets

Suggested by Kyphii

* Add Mako colour scheme

Suggestion by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add two colours to BM Invert

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Bobsleigh Preset

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Woodie Presets

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Looping RC preset

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Flying RC preset

Not based on one specifically, it just looks very nice.

* Update GCI Woodie preset

* Update Inverted RC's presets

Removed the skinworm and added a banshee colour scheme that you could find in the renders. Supports were a tad difficult but I think Violet pops the best with the rails so I decided to go for that.

* Change default Woodie LB Bl Bl to LB Bl DB

* Update ride presets for Twister RC

Removed Aquamarine and Moss Green because you can find Moss Green on the Flying already and Aquamarine is very close to the white.

The white I would probably change to Black & White and move it to the Wing RC once that ride type becomes available.

* Add colour presets for the 4th Dimension RC

* Add Hybrid RC presets

* Add two yellow themes for Impulse

May both rides rest in pieces

* Add colour documentation

* Joker's Jinx colour

For the LIM Launched, based on Premier rides LIM RC.

* Poltergeist colour

Based on a Premier rides LIM RC

* Flight of Fear colour

* Add Mega-Lite colour scheme

* Add colours for Vertical Drop RC

* Add two HyperCoaster presets

Suggested by Kyphii

* Add Mako colour scheme

Suggestion by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add two colours to BM Invert

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Bobsleigh Preset

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Woodie Presets

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Looping RC preset

Suggested by Kyphii

Co-Authored-By: kyphii <8711258+kyphii@users.noreply.github.com>

* Add Flying RC preset

Not based on one specifically, it just looks very nice.

* Update GCI Woodie preset

* Update Inverted RC's presets

Removed the skinworm and added a banshee colour scheme that you could find in the renders. Supports were a tad difficult but I think Violet pops the best with the rails so I decided to go for that.

* Change default Woodie LB Bl Bl to LB Bl DB

* Update ride presets for Twister RC

Removed Aquamarine and Moss Green because you can find Moss Green on the Flying already and Aquamarine is very close to the white.

The white I would probably change to Black & White and move it to the Wing RC once that ride type becomes available.

* Add colour presets for the 4th Dimension RC

* Add Hybrid RC presets

* Add two yellow themes for Impulse

May both rides rest in pieces

* Add changelog entry

* Add Water Coaster colour preset

---------

Co-authored-by: kyphii <8711258+kyphii@users.noreply.github.com>
Co-authored-by: Rik Smeets <30838294+rik-smeets@users.noreply.github.com>
2023-05-21 18:02:28 +02:00
Ted John
0ed4bfbc4a Return null for legacyIdentifier 2023-05-02 20:28:14 +01:00
Ted John
ffe5f74fa3 Update openrct2.d.ts 2023-05-02 20:28:14 +01:00
Ted John
c784084942 Update openrct2.d.ts 2023-05-02 20:28:14 +01:00
Ted John
069a2b3192 Implement object manager for plugins 2023-05-02 20:28:14 +01:00
Ted John
9a20c47f86 Design APIs for loading / unloading objects 2023-05-02 20:28:14 +01:00
Ted John
f95472c70a Add API for installed objects 2023-05-02 20:28:14 +01:00
Ted John
96ef163d51 Add new APIs to openrct2.d.ts 2023-05-02 20:28:14 +01:00
Ted John
f1ac4363ce Fix openrct2.d.ts 2023-05-02 20:28:14 +01:00
Ted John
bf3c6964be Remove scenery from object type names 2023-05-02 20:27:56 +01:00