배우기
엔진 클래스
GamepadService
만들 수 없음
서비스
복제되지 않음

*이 콘텐츠는 AI(베타)를 사용해 번역되었으며, 오류가 있을 수 있습니다. 이 페이지를 영어로 보려면 여기를 클릭하세요.


요약
상속된 멤버

API 참조
속성
GamepadCursorEnabled
Roblox 스크립트 보안
병렬 읽기
기능: Input
GamepadService.GamepadCursorEnabled:boolean
코드 샘플
게임패드 서비스 - 게임패드 커서 활성화 속성
local gamepadService = game.GamepadService
gamepadService:GetPropertyChangedSignal("GamepadCursorEnabled"):Connect(function()
local enabled = gamepadService.GamepadCursorEnabled
if enabled then
-- 가상 커서가 활성화될 때의 사용자 정의 코드
else
-- 가상 커서가 비활성화될 때의 사용자 정의 코드
end
end)

메서드
DisableGamepadCursor
기능: Input
GamepadService:DisableGamepadCursor():()
반환
()
코드 샘플
게임패드 서비스 - 게임패드 커서 비활성화
local gamepadService = game.GamepadService
local userInputService = game.UserInputService
userInputService.InputBegan:Connect(function(inputObject, gameProcessed)
if inputObject.KeyCode == Enum.KeyCode.ButtonB then
gamepadService:DisableGamepadCursor()
end
end)

EnableGamepadCursor
기능: Input
GamepadService:EnableGamepadCursor(guiObject:Instance):()
매개 변수
guiObject:Instance
반환
()
코드 샘플
게임패드 서비스 - 게임패드 커서 활성화
local gamepadService = game.GamepadService
local userInputService = game.UserInputService
local startObject = script.Parent
userInputService.InputBegan:Connect(function(inputObject, gameProcessed)
if inputObject.KeyCode == Enum.KeyCode.ButtonA then
gamepadService:EnableGamepadCursor(startObject)
end
end)

©2026 Roblox Corporation. Roblox 및 Roblox 로고, 'Powering Imagination'은 미국 및 기타 국가 내 당사의 등록 및 미등록 상표입니다.