You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
command -v git-lfs >/dev/null 2>&1|| { echo>&2"\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-checkout' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n";exit 2; }
2
+
command -v git-lfs >/dev/null 2>&1|| { printf>&2"\n%s\n\n""This repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-checkout' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').";exit 2; }
command -v git-lfs >/dev/null 2>&1|| { echo>&2"\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-commit' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n";exit 2; }
2
+
command -v git-lfs >/dev/null 2>&1|| { printf>&2"\n%s\n\n""This repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-commit' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').";exit 2; }
command -v git-lfs >/dev/null 2>&1|| { echo>&2"\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-merge' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n";exit 2; }
2
+
command -v git-lfs >/dev/null 2>&1|| { printf>&2"\n%s\n\n""This repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-merge' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').";exit 2; }
command -v git-lfs >/dev/null 2>&1|| { echo>&2"\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'pre-push' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n";exit 2; }
2
+
command -v git-lfs >/dev/null 2>&1|| { printf>&2"\n%s\n\n""This repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'pre-push' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').";exit 2; }
Copy file name to clipboardExpand all lines: content/en-us/reference/engine/classes/AssetService.yaml
+99-58Lines changed: 99 additions & 58 deletions
Original file line number
Diff line number
Diff line change
@@ -17,6 +17,105 @@ tags:
17
17
deprecation_message: ''
18
18
properties: []
19
19
methods:
20
+
- name: AssetService:CreateAssetAsync
21
+
summary: |
22
+
Creates a new asset from the given object.
23
+
description: |
24
+
Creates a new asset from the given object in Plugin or Open Cloud Luau Execution context.
25
+
code_samples:
26
+
- AssetService-CreateAssetAsync
27
+
parameters:
28
+
- name: object
29
+
type: Object
30
+
default:
31
+
summary: |
32
+
The object to be created as an asset.
33
+
- name: assetType
34
+
type: AssetType
35
+
default:
36
+
summary: |
37
+
Currently supported types are:
38
+
39
+
- `Enum.AssetType.Model` – with `object` as any valid `Class.Instance` root.
40
+
- `Enum.AssetType.Plugin` – with `object` as any valid `Class.Instance` root.
41
+
- `Enum.AssetType.Mesh` – with `object` as any valid `Class.EditableMesh` root.
42
+
- `Enum.AssetType.Image` – with `object` as any valid `Class.EditableImage` root.
43
+
- name: options
44
+
type: Dictionary?
45
+
default:
46
+
summary: |
47
+
Options table containing asset metadata:
48
+
49
+
- `Name` – Name of the asset as a string. Defaults to `[object.Name]`.
50
+
- `Description` – Description of the asset as a string. Defaults to `"Created with AssetService:CreateAssetAsync"`.
51
+
- `CreatorId` – ID of the asset creator as a number. Defaults to the logged in Roblox Studio user for Plugin context. Required for Open Cloud Luau Execution context.
52
+
- `CreatorType` – `Enum.AssetCreatorType` indicating the type of asset creator. Defaults to `Enum.AssetCreatorType.User` in Plugin context. Required for Open Cloud Luau Execution context.
53
+
- `IsPackage` – Boolean value, only applicable to the `Enum.AssetType.Model` type. Defaults to `true`.
54
+
returns:
55
+
- type: Tuple
56
+
summary: |
57
+
The `Enum.CreateAssetResult` and asset ID pair if successful.
58
+
tags:
59
+
- Yields
60
+
deprecation_message: ''
61
+
security: None
62
+
thread_safety: Unsafe
63
+
capabilities:
64
+
- PluginOrOpenCloud
65
+
writeCapabilities:
66
+
- PluginOrOpenCloud
67
+
- name: AssetService:CreateAssetVersionAsync
68
+
summary: |
69
+
Creates a new version for an existing asset from the given object.
70
+
description: |
71
+
Creates a new version for an existing asset from the given object in Plugin or Open Cloud Luau Execution context.
72
+
code_samples:
73
+
- AssetService-CreateAssetVersionAsync
74
+
parameters:
75
+
- name: object
76
+
type: Object
77
+
default:
78
+
summary: |
79
+
The object to be created as an asset.
80
+
- name: assetType
81
+
type: AssetType
82
+
default:
83
+
summary: |
84
+
Currently supported types are:
85
+
86
+
- `Enum.AssetType.Model` – with `object` as any valid `Class.Instance` root.
87
+
- `Enum.AssetType.Plugin` – with `object` as any valid `Class.Instance` root.
88
+
- `Enum.AssetType.Mesh` – with `object` as any valid `Class.EditableMesh` root.
89
+
- `Enum.AssetType.Image` – with `object` as any valid `Class.EditableImage` root.
90
+
- name: targetAssetId
91
+
type: int64
92
+
default:
93
+
summary: |
94
+
The ID of the asset for the new version.
95
+
- name: options
96
+
type: Dictionary?
97
+
default:
98
+
summary: |
99
+
Options table containing asset metadata:
100
+
101
+
- `Name` – A `string`. Name of the asset. Default: object.Name.
102
+
- `Description` – A `string`. Description of the asset. Default: "Created with AssetService:CreateAssetAsync".
103
+
- `CreatorId` – A `number`. ID of the asset creator. Default: The logged in Roblox Studio user for Plugin context. Required for Open Cloud Luau Execution context.
104
+
- `CreatorType` – A `Enum.AssetCreatorType`. Type of asset creator. Default: `Enum.AssetCreatorType.User` in Plugin context. Required for Open Cloud Luau Execution context.
105
+
- `IsPackage` – A `bool`. Only applicable to the `Enum.AssetType.Model` type. Default: true.
106
+
returns:
107
+
- type: Tuple
108
+
summary: |
109
+
The `Enum.CreateAssetResult` and asset version number pair if successful.
110
+
tags:
111
+
- Yields
112
+
deprecation_message: ''
113
+
security: None
114
+
thread_safety: Unsafe
115
+
capabilities:
116
+
- PluginOrOpenCloud
117
+
writeCapabilities:
118
+
- PluginOrOpenCloud
20
119
- name: AssetService:CreateEditableImage
21
120
summary: |
22
121
Creates a new `Class.EditableImage`.
@@ -88,64 +187,6 @@ methods:
88
187
thread_safety: Unsafe
89
188
capabilities: []
90
189
writeCapabilities: []
91
-
- name: AssetService:CreateAssetAsync
92
-
summary: ''
93
-
description: ''
94
-
code_samples: []
95
-
parameters:
96
-
- name: object
97
-
type: Object
98
-
default:
99
-
summary: ''
100
-
- name: assetType
101
-
type: AssetType
102
-
default:
103
-
summary: ''
104
-
- name: requestParameters
105
-
type: Dictionary
106
-
default: nil
107
-
summary: ''
108
-
returns:
109
-
- type: Tuple
110
-
summary: ''
111
-
tags:
112
-
- Yields
113
-
deprecation_message: ''
114
-
security: None
115
-
thread_safety: Unsafe
116
-
capabilities: []
117
-
writeCapabilities: []
118
-
- name: AssetService:CreateAssetVersionAsync
119
-
summary: ''
120
-
description: ''
121
-
code_samples: []
122
-
parameters:
123
-
- name: object
124
-
type: Object
125
-
default:
126
-
summary: ''
127
-
- name: assetType
128
-
type: AssetType
129
-
default:
130
-
summary: ''
131
-
- name: assetId
132
-
type: int64
133
-
default:
134
-
summary: ''
135
-
- name: requestParameters
136
-
type: Dictionary
137
-
default: nil
138
-
summary: ''
139
-
returns:
140
-
- type: Tuple
141
-
summary: ''
142
-
tags:
143
-
- Yields
144
-
deprecation_message: ''
145
-
security: None
146
-
thread_safety: Unsafe
147
-
capabilities: []
148
-
writeCapabilities: []
149
190
- name: AssetService:CreateEditableImageAsync
150
191
summary: |
151
192
Creates a new `Class.EditableImage` object populated with the given image.
0 commit comments