Giftoin Docs
  • 👋INTRODUCTION
    • Welcome to Giftoin
    • Overview
    • Quick Start
    • FAQs
    • Key Features
  • 🧩API REFERENCE
    • Standards and Conventions
    • Orders API
      • Tokens/Points
      • Collectibles/Cards
      • Collectibles/Random Cards
    • Users API
      • Inventory
      • Progress
    • Error Handling
  • 💻PLATFORM GUIDES
    • Roblox
      • Why use Giftoin?
      • Basic Usage
      • Developer Access
      • Installation
      • Additional Example / Use-Cases
        • Point Reward
        • Daily Reward
        • Advanced Point Distribution System
        • Managed Codes & In-Game Rewards (Coming Soon)
          • Registering Reward Types
      • Tools and Scripts
        • Rotating Script
        • Floating Script
        • Quest System (Coming Soon)
    • Discord
      • Introduction
      • Getting Started
      • Command Reference
      • Role System
      • User Guides
      • Troubleshooting
      • FAQs
    • Wordpress
  • 📚Resources
    • Use Cases
      • Basic
      • eCommerce
      • Games
    • Support
Powered by GitBook
On this page
  • How to Use:
  • Customization:
  • Example Use Cases:

Was this helpful?

  1. PLATFORM GUIDES
  2. Roblox
  3. Tools and Scripts

Rotating Script

This script allows you to easily create a rotating effect for objects in your game, such as coins, power-ups, or decorative elements.

PreviousTools and ScriptsNextFloating Script

Was this helpful?

local coin = script.Parent

local function rotate ()
	while true do
		coin.Orientation = coin.Orientation + Vector3.new(0, 3, 0)
		wait()
	end
end

rotate()

How to Use:

  1. Create a new Script in Roblox Studio.

  2. Copy and paste the above code into the script.

  3. Place the script as a child of the object you want to rotate.

  4. The object will now rotate continuously around its Y-axis.

Customization:

  • To change the rotation speed or axis, modify the Vector3 values:

    • Vector3.new(X, Y, Z):

      • X controls rotation around the X-axis

      • Y controls rotation around the Y-axis

      • Z controls rotation around the Z-axis

  • Increase the numbers for faster rotation, decrease for slower rotation.

Example Use Cases:

  • Rotating coins or collectibles

  • Creating spinning power-ups

  • Animating decorative elements in your game world

💻