Merge pull request 'add doc pickup feature' (#110) from feature/add-doc-pickup into develop
Reviewed-on: #110 Reviewed-by: Pham Huynh Duc Huy <huy.pham@mercurystudiogroup.com>
This commit is contained in:
commit
31095d8661
18
api-doc/slot-machine/pickup/_category_.json
Normal file
18
api-doc/slot-machine/pickup/_category_.json
Normal file
@ -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"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
91
api-doc/slot-machine/pickup/pickup-controller.md
Normal file
91
api-doc/slot-machine/pickup/pickup-controller.md
Normal file
@ -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) |
|
58
api-doc/slot-machine/pickup/pickup-model.md
Normal file
58
api-doc/slot-machine/pickup/pickup-model.md
Normal file
@ -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) |
|
||||||
|
|
||||||
|
<p style={{ color: 'gray', fontSize: '1.0em' }}>
|
||||||
|
|
||||||
|
**Parameters**
|
||||||
|
- `result` [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)
|
||||||
|
</p>
|
||||||
|
---
|
||||||
|
|
||||||
|
#### 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) |
|
59
api-doc/slot-machine/pickup/pickup-view.md
Normal file
59
api-doc/slot-machine/pickup/pickup-view.md
Normal file
@ -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) |
|
||||||
|
|
||||||
|
<p style={{ color: 'gray', fontSize: '1.0em' }}>
|
||||||
|
|
||||||
|
**Parameters**
|
||||||
|
- `itemID` [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)
|
||||||
|
</p>
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### 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) |
|
||||||
|
|
||||||
|
<p style={{ color: 'gray', fontSize: '1.0em' }}>
|
||||||
|
|
||||||
|
**Parameters**
|
||||||
|
- `result` [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)
|
||||||
|
</p>
|
Loading…
x
Reference in New Issue
Block a user