> For the complete documentation index, see [llms.txt](/llms.txt)

# Equipment Enchantment

Rolls random bonuses onto equipment, with configurable slot counts, options and weights.




**이 데모에 대하여**

데모는 익명 계정으로 자동 로그인합니다. 이 계정은 쇼룸의 모든 데모에서 공유되므로 한 데모에서 얻은 아이템이나 재화가 다른 데모에도 반영됩니다. 로딩에 약간 시간이 걸립니다. 화면이 작다면 새 탭에서 열어 사용해 보세요.

## 개요

Each piece of equipment you take rolls 1 to 3 random bonuses (enchantments) of its own. Bonuses are drawn by weight from six options (`attack`, `defense`, `hp`, `speed`, `critical`, `luck`) and shown on the piece's row as text such as `attack +12 / hp +50`. You can spend coins to reroll the bonuses or to add one more.

## 체험 방법

1. Press **Deposit** under **Get coins** to put 100 free coins into **Free balance** under **Your coins**.
1. Press **Take** next to an equipment name under **Take equipment**. The piece appears under **Your equipment and its bonuses**, and the first time it is read it rolls 1 to 3 bonuses (one is most likely, three is rare).
1. Press **Reroll** on a piece to pay 10 coins and draw the same number of bonuses again.
1. Press **Add bonus** to pay 30 coins and draw one more bonus. If the piece already holds the maximum of 3, the press fails and no coins are taken.
1. If the bag runs out of room, press **Expand** under **Equipment bag** to add 2 slots (up to 10).

**How enchanting works** states the rules for how many bonuses a piece gets and what each press costs. Two pieces with the same name are separate items, and each rolls its own bonuses.

## 사용하는 GS2 서비스

- [GS2-Enchant](/ko/microservices/enchant/): GS2-Enchant's rarity parameter model `standard` defines the maximum of 3 bonuses, the weights for how many are rolled, and the six options with their values. Bonuses are kept per piece (the item set's `propertyId`); rerolling uses `Gs2Enchant:ReDrawRarityParameterStatusByUserId` and adding uses `Gs2Enchant:AddRarityParameterStatusByUserId`.
- [GS2-Exchange](/ko/microservices/exchange/): GS2-Exchange rate models define **Reroll** and **Add bonus** as single transactions that take the coins and change the enchantment, run atomically on the server. Taking equipment, expanding the bag and depositing free coins also go through exchange rates.
- [GS2-Inventory](/ko/microservices/inventory/): GS2-Inventory holds the equipment the player has taken and the bag it goes in (4 slots to start, 10 at most).
- [GS2-Money2](/ko/microservices/money2/): A GS2-Money2 wallet holds the coins; **Reroll** withdraws 10 and **Add bonus** withdraws 30.

## GS2 Studio에서 사용하기

GS2 Studio의 Simple 모드에서 **Add features** 를 열고 **Equipment Enchantment** 의 **Add** 를 누르면 이 기능을 자신의 프로젝트에 가져올 수 있습니다. 패키지를 직접 지정하려면 **Add from GitHub** 를 선택하고 아래 패키지를 입력합니다.

```text
https://github.com/gs2io/gs2-studio-package/tree/main/micro-economy-equipment-enchant/packages/micro-economy-equipment-enchant
```

- Owner: `gs2io`
- Repository: `gs2-studio-package`
- Subdirectory: `micro-economy-equipment-enchant/packages/micro-economy-equipment-enchant`

## 소스 코드

- 데모 프로젝트: <https://github.com/gs2io/gs2-studio-package/tree/main/micro-economy-equipment-enchant/live-demo>
- 기능 패키지: <https://github.com/gs2io/gs2-studio-package/tree/main/micro-economy-equipment-enchant>



