Addon Wheel Spin
Last updated
Last updated
If you're looking for custom addons to enhance your game, feel free to reach out! Drop us an email at rafbizachi5@gmail.com with the details of what you need, and we'll gladly provide you with a no-obligation quote.
If you come across any bugs or have suggestions for urgent improvements to this addon, please feel free to reach out via email with the details. I'd greatly appreciate it!
The LuckyWheelManager
script controls the functionality of the Lucky Wheel feature in your game. By adjusting the public variables exposed in the Unity Inspector, you can customize the wheel's behavior, prizes, UI elements, and overall player experience.
Below is a detailed explanation of each editable public variable, organized by their respective headers.
commonPrizes
)Type: List<PrizeWheelItem>
Description: A list of regular prizes that can appear on the wheel segments.
How to Use:
Add or Remove Prizes: Populate this list with PrizeWheelItem
objects representing the common rewards.
Enhancing Attractiveness: Vary the types and quantities of common prizes to keep players engaged. Include a mix of currencies and small rewards.
grandPrizes
)Type: List<PrizeWheelItem>
Description: A list of grand prizes that are more valuable and rarer than common prizes.
How to Use:
Add or Remove Prizes: Populate this list with PrizeWheelItem
objects representing the grand rewards.
Enhancing Attractiveness: Introduce exclusive or highly desirable items as grand prizes to motivate players to spin the wheel frequently.
currentGrandPrize
)Type: PrizeWheelItem
Description: The grand prize currently featured on the wheel.
How to Use:
Automatic Assignment: Typically managed by the script; you don't need to set this manually.
Enhancing Attractiveness: Ensure that the grand prizes rotate or update regularly to maintain player interest.
reservePrize
)Type: PrizeWheelItem
Description: A fallback prize used to fill wheel segments when there aren't enough prizes.
How to Use:
Set a Prize: Assign a PrizeWheelItem
that will act as a default reward.
Enhancing Attractiveness: Choose a prize that's still appealing to players, such as a small amount of premium currency, to prevent the wheel from feeling empty or repetitive.
wheelTransform
)Type: Transform
Description: The transform component of the wheel object used for rotation.
How to Use:
Assign the Wheel Object: Drag the wheel GameObject from the scene hierarchy into this field.
Enhancing Attractiveness: Ensure the wheel's pivot point is correctly set for smooth rotation animations.
spinDuration
)Type: float
Description: The duration (in seconds) of the wheel spin animation.
How to Use:
Adjust Spin Time: Set how long the wheel takes to complete a spin.
Enhancing Attractiveness: A moderate duration (e.g., 3-5 seconds) balances excitement and pacing. Shorter spins create a fast-paced experience, while longer spins build anticipation.
spinButton
)Type: Button
Description: The button that players press to spin the wheel.
How to Use:
Assign the Button Object: Drag the spin button GameObject into this field.
Enhancing Attractiveness: Style the button to stand out and entice players to interact with it. Consider adding visual effects on hover or click.
spinCostText
)Type: TextMeshProUGUI
Description: The UI text element displaying the cost to spin the wheel.
How to Use:
Assign the Text Object: Drag the text GameObject into this field.
Enhancing Attractiveness: Ensure the text is clear and readable. Use styling that matches the game's theme.
spinCostCurrencyIcon
)Type: Image
Description: The UI image displaying the icon of the currency required to spin the wheel.
How to Use:
Assign the Image Object: Drag the image GameObject into this field.
Enhancing Attractiveness: Use a high-quality icon that visually represents the currency, making it immediately recognizable to players.
spinCostCurrencyId
)Type: string
Description: The identifier of the currency required to spin the wheel (e.g., "Coin", "Gem").
How to Use:
Set Currency ID: Enter the exact ID matching the currency defined in your monetization system.
Enhancing Attractiveness: Adjust the currency type to align with your game's economy. Using premium currency can increase monetization opportunities, while using standard currency encourages regular engagement.
spinCostAmount
)Type: int
Description: The amount of currency required to spin the wheel.
How to Use:
Set Cost Amount: Define how much the spin will cost the player.
Enhancing Attractiveness: Balance the cost to make spins accessible but still valuable. Consider offering discounted or free spins periodically to boost player engagement.
prizePopup
)Type: GameObject
Description: The popup UI displayed when a player wins a prize.
How to Use:
Assign the Popup Object: Drag the prize popup GameObject into this field.
Enhancing Attractiveness: Design an eye-catching popup with animations and effects to celebrate the player's win, enhancing the reward experience.
prizeIcon
)Type: Image
Description: The UI image displaying the icon of the won prize in the popup.
How to Use:
Assign the Image Object: Drag the image component into this field.
Enhancing Attractiveness: Use high-resolution icons and consider adding particle effects or animations to the prize icon when displayed.
prizeTitleText
)Type: TextMeshProUGUI
Description: The UI text element displaying the title of the won prize.
How to Use:
Assign the Text Object: Drag the text component into this field.
Enhancing Attractiveness: Use stylized fonts and colors that match your game's theme. Make the prize name prominent to highlight the reward.
prizeQuantityText
)Type: TextMeshProUGUI
Description: The UI text element displaying the quantity of the won prize (if applicable).
How to Use:
Assign the Text Object: Drag the text component into this field.
Enhancing Attractiveness: Clearly display the quantity won, especially for currency prizes, to ensure players understand their rewards.
bigWinFrame
)Type: Image
Description: A special UI frame or effect used when the player wins a grand prize.
How to Use:
Assign the Image Object: Drag the image component into this field.
Enhancing Attractiveness: Create an exciting visual effect or animation to emphasize the significance of winning a grand prize.
segmentSlots
)Type: List<Transform>
Description: A list of transforms representing the positions where wheel segments (prizes) will be placed.
How to Use:
Assign Slot Transforms: Populate this list with the transforms of each segment slot on your wheel.
Enhancing Attractiveness: Ensure that the slots are evenly spaced and aligned for a balanced and visually appealing wheel.
segmentPrefab
)Type: SegmentEntry
Description: The prefab used for each wheel segment displaying a prize.
How to Use:
Assign the Prefab: Drag your SegmentEntry
prefab into this field.
Enhancing Attractiveness:
Design Quality: Use high-quality graphics and animations in the segment prefab.
Variations: Customize the appearance of different segments to reflect the value or rarity of prizes.
historyContainer
)Type: Transform
Description: The parent transform where prize history entries will be displayed.
How to Use:
Assign the Container: Drag the transform of the history UI panel into this field.
Enhancing Attractiveness: Allow players to view their win history, fostering a sense of progression and achievement.
historyEntryPrefab
)Type: HistoryEntry
Description: The prefab used for displaying individual entries in the prize history.
How to Use:
Assign the Prefab: Drag your HistoryEntry
prefab into this field.
Enhancing Attractiveness: Design an appealing history entry with clear information and visuals to encourage players to review their past wins.
bigWinEntryPrefab
)Type: BigWinEntry
Description: The prefab used to display the current grand prize in the UI.
How to Use:
Assign the Prefab: Drag your BigWinEntry
prefab into this field.
Enhancing Attractiveness: Showcase the grand prize prominently to motivate players to spin the wheel.
bigWinContainer
)Type: Transform
Description: The parent transform where the current grand prize display will be placed.
How to Use:
Assign the Container: Drag the transform for the grand prize UI area into this field.
Enhancing Attractiveness: Use animations or effects to draw attention to the grand prize.
nextGrandPrizesContainer
)Type: Transform
Description: The parent transform where upcoming grand prizes will be displayed.
How to Use:
Assign the Container: Drag the transform for the upcoming grand prizes UI area into this field.
Enhancing Attractiveness: Tease future grand prizes to keep players engaged and anticipating future rewards.
nextGrandPrizeEntryPrefab
)Type: NextGrandPrizeEntry
Description: The prefab used for displaying entries of upcoming grand prizes.
How to Use:
Assign the Prefab: Drag your NextGrandPrizeEntry
prefab into this field.
Enhancing Attractiveness: Design enticing visuals for upcoming grand prizes to encourage continued play.
wheelPointer
)Type: Transform
Description: The transform of the pointer or indicator that shows which prize is selected when the wheel stops.
How to Use:
Assign the Pointer Transform: Drag the pointer GameObject into this field.
Enhancing Attractiveness: Ensure the pointer is visually clear and aligns accurately with the wheel segments.
bigWinGachaRate
)Type: float
Description: The percentage chance (0-100%) of winning the grand prize on each spin.
How to Use:
Set Win Rate: Adjust this value to control how often players can win the grand prize.
Enhancing Attractiveness: Balance the win rate to make the grand prize feel special but attainable. A very low rate increases rarity, while a higher rate can boost excitement.
guaranteeBigWinAfterSpins
)Type: bool
Description: Determines whether the grand prize is guaranteed after a certain number of spins.
How to Use:
Enable or Disable Guarantee: Check or uncheck this option to control the guarantee mechanic.
Enhancing Attractiveness: Enabling this feature can encourage players to keep spinning, knowing they will eventually win the grand prize.
spinsUntilGuaranteedBigWin
)Type: int
Description: The number of spins required to guarantee a grand prize win if guaranteeBigWinAfterSpins
is enabled.
How to Use:
Set Required Spins: Define how many spins are needed before the grand prize is guaranteed.
Enhancing Attractiveness: Choose a reasonable number that keeps players engaged without causing frustration.
messageError
)Type: TextMeshProUGUI
Description: The UI text element used to display error messages to the player.
How to Use:
Assign the Text Object: Drag the text component into this field.
Enhancing Attractiveness: Use this to provide feedback, such as when the player lacks sufficient currency. Style the text to match the game's aesthetics.
Visual Design: Invest in high-quality graphics, animations, and effects for all UI elements to create an engaging and polished experience.
Sound Effects and Music: Incorporate satisfying sound effects and background music to enhance the excitement of spinning the wheel and winning prizes.
User Feedback: Provide immediate and positive feedback when players interact with the wheel, such as button animations, wheel sounds, and prize celebration effects.
Variety of Prizes: Offer a diverse range of prizes, including rare and exclusive items, to maintain player interest and encourage repeated spins.
Balancing Mechanics: Carefully balance the spin cost, prize values, and win rates to ensure the feature feels rewarding without being exploitable.
Limited-Time Events: Introduce time-limited grand prizes or special events to create urgency and encourage players to engage more frequently.
Social Sharing: Allow players to share their big wins on social media, increasing engagement and attracting new players.
Progression Indicators: Show players their progress towards guaranteed grand prizes or other milestones to motivate continued play.
Localization: If targeting a global audience, ensure that all text elements are localized to the appropriate languages.
If you're looking for custom addons to enhance your game, feel free to reach out! Drop us an email at rafbizachi5@gmail.com with the details of what you need, and we'll gladly provide you with a no-obligation quote.