diff --git a/api-doc/slot-machine/pickup/_category_.json b/api-doc/slot-machine/pickup/_category_.json new file mode 100644 index 0000000..7837c24 --- /dev/null +++ b/api-doc/slot-machine/pickup/_category_.json @@ -0,0 +1,18 @@ +{ + "position": 27, + "label": "Pickup", + "collapsible": true, + "collapsed": true, + "link": { + "type": "generated-index", + "title": "Pickup", + "description": "This section will guide you through the process of setting up a new project, including creating a new repository and configuring your development environment.", + "keywords": [ + "controller", + "project", + "repository", + "model", + "pickup" + ] + } +} \ No newline at end of file diff --git a/api-doc/slot-machine/pickup/pickup-controller.md b/api-doc/slot-machine/pickup/pickup-controller.md new file mode 100644 index 0000000..492abd0 --- /dev/null +++ b/api-doc/slot-machine/pickup/pickup-controller.md @@ -0,0 +1,91 @@ +--- +sidebar_position: 1 +--- +# Pickup Controller +--- + +## Index + +### Methods + +- [_registerEvent](#_registerevent) — Registers events related to pickups. +- [onViewPickupItem](#onviewpickupitem) — Handles item selection initiated from the view. +- [onViewPresentPickupResultCompleted](#onviewpresentpickupresultcompleted) — Handles result display completion from the view. +- [onPickupItemReceived](#onpickupitemreceived) — Handles the event when an item result is received. +- [onPickupReady](#onpickupready) — Called when the pickup feature becomes available. +- [pickup](#pickup) — Sends a request to pick up an item. +- [pickupEnd](#pickupend) — Handles the end of the pickup feature and notifies listeners. + +--- + +## Details + +### Methods + +#### _registerEvent + +Registers events related to pickups. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L17](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L17) | + +--- + +#### onViewPickupItem + +Handles item selection initiated from the view. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L23](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L23) | + +--- + +#### onViewPresentPickupResultCompleted + +Handles result display completion from the view. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L30](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L30) | + +--- + +#### onPickupItemReceived + +Handles the event when an item result is received.. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L37](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L37) | + +--- + +#### onPickupReady + +Called when the pickup feature becomes available. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L45](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L45) | + +--- + +#### pickup + +Sends a request to pick up an item + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L55](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L55) | + +--- + +#### pickupEnd + +Handles the end of the pickup feature and notifies listeners. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/controller/pickup-controller.js#L63](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/controller/pickup-controller.js#L63) | \ No newline at end of file diff --git a/api-doc/slot-machine/pickup/pickup-model.md b/api-doc/slot-machine/pickup/pickup-model.md new file mode 100644 index 0000000..b917dd9 --- /dev/null +++ b/api-doc/slot-machine/pickup/pickup-model.md @@ -0,0 +1,58 @@ +--- +sidebar_position: 2 +--- +# Pickup Model + +## Index + +### Properties + +- [pickupResult](#pickupresult) — Stores the result of the pickup. + +### Methods + +- [SetPickupResult](#setpickupresult) — Updates the current pickup result. +- [GetPickupResult](#getpickupresult) — Returns the current pickup result stored in the model. + +--- + +## Details + +### Properties + +#### pickupResult + +> Stores the result of the pickup. + +| Meta | Description | +|------|-------------| +| Type | [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) | +| Defined in | [p4f-slotty-core/src/model/pickup-model.js#L8](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/model/pickup-model.js#L8) | + +--- + +### Methods + +#### SetPickupResult + +Updates the current pickup result. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/model/pickup-model.js#L13](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/model/pickup-model.js#L13) | + +

+ + **Parameters** +- `result` [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) +

+--- + +#### GetPickupResult + +Returns the current pickup result stored in the model + +| Meta | Description | +|------|-------------| +| Returns | Object | +| Defined in | [p4f-slotty-core/src/model/pickup-model.js#L18](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/model/pickup-model.js#L18) | diff --git a/api-doc/slot-machine/pickup/pickup-view.md b/api-doc/slot-machine/pickup/pickup-view.md new file mode 100644 index 0000000..2759d86 --- /dev/null +++ b/api-doc/slot-machine/pickup/pickup-view.md @@ -0,0 +1,59 @@ +--- +sidebar_position: 3 +--- + +# Pickup View + +## Index + +### Methods + +- [PickupItem](#pickupitem) — Triggers item pickup event. +- [PresentPickupResultCompleted](#presentpickupresultcompleted) — Notifies when pickup result display is complete. +- [PresentPickupResult](#presentpickupresult) — Emits the result of a pickup event. + +--- + +## Details + +### Methods + +#### PickupItem + +Triggers item pickup event. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/view/pickup-view.js#L14](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/view/pickup-view.js#L14) | + +

+ + **Parameters** +- `itemID` [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) +

+ +--- + +#### PresentPickupResultCompleted + +Notifies when pickup result display is complete + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/view/pickup-view.js#L19](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/view/pickup-view.js#L19) | + +--- + +#### PresentPickupResult + +Emits the result of a pickup event. + +| Meta | Description | +|------|-------------| +| Defined in | [p4f-slotty-core/src/view/pickup-view.js#L24](https://gitea.plp19.com/cocos-core/p4f-slotty-core/src/commit/7fbf58bf2ad8edec4258757b353151b638c96652/src/view/pickup-view.js#L24) | + +

+ + **Parameters** +- `result` [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) +