0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

robloxでassistant その86

Posted at

概要

robloxでassistantやってみた。
練習問題やってみた。

練習問題

Trailを使え。

手順

  • ServerScriptServiceに、scriptを追加。
  • スクリプトを書く。

local TweenService = game:GetService("TweenService")
local part = Instance.new("Part")
part.Material = Enum.Material.Neon
part.Size = Vector3.new(1, 1, 1)
part.Shape = Enum.PartType.Ball
part.Position = Vector3.new(0, 5, 0)
part.Anchored = true
part.Parent = workspace
local attachment0 = Instance.new("Attachment")
attachment0.Name = "Attachment0"
attachment0.Position = Vector3.new(0, -0.5, 0)
attachment0.Parent = part
local attachment1 = Instance.new("Attachment")
attachment1.Name = "Attachment1"
attachment1.Position = Vector3.new(0, 0.5, 0)
attachment1.Parent = part
local trail = Instance.new("Trail")
trail.Attachment0 = attachment0
trail.Attachment1 = attachment1
local color1 = Color3.fromRGB(255, 255, 255)
local color2 = Color3.fromRGB(255, 255, 255)
trail.Color = ColorSequence.new(color1, color2)
trail.Parent = part
local dir = 15
while true do
	dir *= -1
	local goal = {
		Position = part.Position + Vector3.new(0, 0, dir)
	}
	local tweenInfo = TweenInfo.new(3)
	local tween = TweenService:Create(part, tweenInfo, goal)
	tween:Play()
	task.wait(4)
end


写真

image.png

以上。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?