Skip to content

Commit d04c878

Browse files
update Open Source Docs from Roblox internal teams
1 parent 3768d20 commit d04c878

File tree

11 files changed

+39
-20
lines changed

11 files changed

+39
-20
lines changed
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 2 additions & 2 deletions
Loading
Lines changed: 2 additions & 2 deletions
Loading
Lines changed: 2 additions & 2 deletions
Loading

content/en-us/input/gamepad.md

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -178,15 +178,7 @@ The following are common input binds that will help players immediately feel fam
178178

179179
Many gamepad controllers have motors built in to provide haptic feedback. Adding rumbles and vibrations can greatly enhance a player's experience and provide subtle feedback beyond visuals or audio.
180180

181-
Roblox supports haptics for the following devices:
182-
183-
- Android and iOS phones supporting haptics including most iPhone, Pixel, and
184-
Samsung Galaxy devices
185-
- PlayStation gamepads
186-
- Xbox gamepads
187-
- Quest Touch controller
188-
189-
Haptic feedback is managed through `Class.HapticEffect` instances which can be set to a specific `Class.HapticEffect.Type|Type` such as `Enum.HapticEffectType|GameplayCollision` or `Enum.HapticEffectType|UIClick`.
181+
Roblox supports haptics for PlayStation gamepads, Xbox gamepads, and the Quest Touch controller. Haptic feedback is managed through `Class.HapticEffect` instances which can be set to a specific `Class.HapticEffect.Type|Type` such as `Enum.HapticEffectType|GameplayCollision` or `Enum.HapticEffectType|UIClick`.
190182

191183
Once a `Class.HapticEffect` is in place, you can initiate it through the `Class.HapticEffect:Play()|Play()` method, for instance:
192184

content/en-us/input/mobile.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,25 @@ local playerGUI = Players.LocalPlayer:WaitForChild("PlayerGui")
107107
print(playerGUI.CurrentScreenOrientation)
108108
```
109109

110+
## Haptic feedback
111+
112+
Most mobile devices have motors built in to provide haptic feedback. Adding rumbles and vibrations can greatly enhance a player's experience and provide subtle feedback beyond visuals or audio.
113+
114+
Roblox supports haptics for haptic-capable devices including most iPhone, Pixel, and Samsung Galaxy devices. Haptic feedback is managed through `Class.HapticEffect` instances which can be set to a specific `Class.HapticEffect.Type|Type` such as `Enum.HapticEffectType|GameplayCollision` or `Enum.HapticEffectType|UIClick`.
115+
116+
Once a `Class.HapticEffect` is in place, you can initiate it through the `Class.HapticEffect:Play()|Play()` method, for instance:
117+
118+
```lua
119+
local Workspace = game:GetService("Workspace")
120+
121+
local effect = Instance.new("HapticEffect")
122+
effect.Type = Enum.HapticEffectType.GameplayExplosion
123+
effect.Parent = Workspace
124+
125+
-- Play the haptic effect
126+
effect:Play()
127+
```
128+
110129
## Detect other devices
111130

112131
In cross-platform experiences, it's important to reference the player's preferred input options by displaying input options for the actively used device. For example, a mobile device can have a [mouse and keyboard](./mouse-and-keyboard.md) or [gamepad](./gamepad.md) connected, or it's possible that a desktop has a touchscreen enabled. If multiple input sources are enabled, you can use `Class.UserInputService:GetLastInputType()|GetLastInputType()` to get the player's last used input device.

content/en-us/production/localization/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: An overview of localization tools you can use to make sure all user
55

66
Roblox users come from a variety of cultures around the world and speak
77
different languages. Using **localization** tools effectively makes sure all
8-
users can understand and enjoy your experience as intended. Any experience can immediately take advantage of Roblox's automatic localization tools instantly expand your potential audience. As your experience grows, use Roblox's various localization API tools, manual translator portals, and analytics, to ensure that users from around the world can fully participate and socialize in your experience.
8+
users can understand and enjoy your experience as intended. Any experience can immediately take advantage of Roblox's automatic localization tools to instantly expand your potential audience. As your experience grows, use Roblox's various localization API tools, manual translator portals, and analytics, to ensure that users from around the world can fully participate and socialize in your experience.
99

1010
<img src="../../assets/localization/Concept-Banner.jpg" width="80%" />
1111

0 commit comments

Comments
 (0)