@zilibobi/forge-vfx 2.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +82 -0
- package/README.md +45 -0
- package/out/ForgeVFX.rbxm +0 -0
- package/out/index.d.ts +78 -0
- package/out/init.luau +1 -0
- package/package.json +34 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
SPDX-License-Identifier: VFX-DL-1.1
|
|
2
|
+
|
|
3
|
+
Preamble.
|
|
4
|
+
Disclaimer: nothing stated in this preamble is legal advice.
|
|
5
|
+
|
|
6
|
+
This is a simple license that allows anyone to use the emit module in their Roblox games.
|
|
7
|
+
|
|
8
|
+
1. You cannot use the module in anything that isn't a Roblox game. For example, it means
|
|
9
|
+
that you cannot create a plugin using this module.
|
|
10
|
+
|
|
11
|
+
2. You are allowed to use the module commercially in your games.
|
|
12
|
+
|
|
13
|
+
3. You are free to share the module with other developers so they can use it in their games,
|
|
14
|
+
as long as the license is retained.
|
|
15
|
+
|
|
16
|
+
4. You can modify and share the module as long as you follow the terms of the license. All
|
|
17
|
+
derivates of the module must have the same license.
|
|
18
|
+
|
|
19
|
+
5. If you break the terms and conditions of the license, you are required to stop the use and
|
|
20
|
+
distribution of the module immediately.
|
|
21
|
+
|
|
22
|
+
End of preamble.
|
|
23
|
+
|
|
24
|
+
VFX Forge Developer License (VFX-DL) Version 1.1
|
|
25
|
+
|
|
26
|
+
Copyright (c) 2025 zilibobi
|
|
27
|
+
|
|
28
|
+
1. Definitions.
|
|
29
|
+
- "Module" means the source code and any compiled form of the Emit Module.
|
|
30
|
+
- "You" means any individual or organization exercising the rights granted herein.
|
|
31
|
+
- "Derivative Work" means any work based upon or incorporating the Module.
|
|
32
|
+
- "Roblox Experience" means a user-facing game or simulation that runs on the
|
|
33
|
+
Roblox platform, created using Roblox Studio and played via the Roblox client.
|
|
34
|
+
|
|
35
|
+
2. Grant of Rights.
|
|
36
|
+
Permission is hereby granted, free of charge, to You to use, reproduce,
|
|
37
|
+
prepare Derivative Works of, publicly display, publicly perform, sublicense,
|
|
38
|
+
and distribute the Module, **solely when embedded in the runtime environment of
|
|
39
|
+
a Roblox Experience** (including playtesting in Roblox Studio), and **not** when
|
|
40
|
+
loaded by any Roblox Studio plugin or other developer tool, running in any context
|
|
41
|
+
that has access to API methods or permissions unavailable to runtime scripts within
|
|
42
|
+
Roblox Experiences (excluding the Roblox Studio command bar feature, when used for
|
|
43
|
+
the purpose of viewing finished effects). You may distribute the Module or Derivative
|
|
44
|
+
Work to other developers, provided they use it only within the permitted runtime
|
|
45
|
+
context described above.
|
|
46
|
+
|
|
47
|
+
3. Conditions.
|
|
48
|
+
a. Copyleft.
|
|
49
|
+
Any Derivative Work, including modified or extended versions of the Module, that
|
|
50
|
+
You distribute must be licensed under the exact same terms as this VFX-DL.
|
|
51
|
+
b. Redistribution.
|
|
52
|
+
You must include a copy of this license text with any distribution of the Module or Derivative Work.
|
|
53
|
+
c. No Other Contexts.
|
|
54
|
+
You may not embed, load, or distribute the Module within any Roblox Studio
|
|
55
|
+
plugin, editor extension, command-line tool, test harness, or any code running
|
|
56
|
+
under Studio outside of normal game runtime.
|
|
57
|
+
|
|
58
|
+
4. Disclaimer of Warranty.
|
|
59
|
+
The Module is provided "AS IS," without warranty of any kind, express or implied,
|
|
60
|
+
including but not limited to the warranties of merchantability, fitness for a
|
|
61
|
+
particular purpose, and noninfringement.
|
|
62
|
+
|
|
63
|
+
5. Limitation of Liability.
|
|
64
|
+
In no event shall the authors or copyright holders be liable for any claim,
|
|
65
|
+
damages, or other liability arising from, out of, or in connection with the
|
|
66
|
+
Module or the use or other dealings in the Module.
|
|
67
|
+
|
|
68
|
+
6. Termination.
|
|
69
|
+
If You violate the terms of this License, Your rights under this VFX-DL will
|
|
70
|
+
terminate automatically. Upon termination, You must cease all use and distribution
|
|
71
|
+
of the Module and any Derivative Works.
|
|
72
|
+
|
|
73
|
+
7. Versioning.
|
|
74
|
+
This license applies to Version 1.0 of the VFX-DL. Future versions may be published
|
|
75
|
+
by the copyright holder.
|
|
76
|
+
|
|
77
|
+
8. Commercial use.
|
|
78
|
+
This License permits commercial use within the scope defined in Section 2.
|
|
79
|
+
|
|
80
|
+
9. Trademarks and branding.
|
|
81
|
+
Nothing in this License grants permission to use the trade names, trademarks, service marks,
|
|
82
|
+
or product names of the Licensor.
|
package/README.md
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+

|
|
2
|
+
|
|
3
|
+
<div align="center">
|
|
4
|
+
<a href="https://docs.zilibobi.dev/vfx-forge"><img alt="View Documentation" src="https://img.shields.io/badge/Documentation-View?style=for-the-badge&label=View&color=c4a7e7"></a>
|
|
5
|
+
<a href="https://discord.gg/Qme9KPN3pF"><img alt="Join Discord" src="https://img.shields.io/discord/1401872327162986626?logo=discord&style=for-the-badge&color=c4a7e7&logoColor=ffffff&label=Join%20Discord"></a>
|
|
6
|
+
</div>
|
|
7
|
+
|
|
8
|
+
# Emit Module
|
|
9
|
+
|
|
10
|
+
The is the official repository for the emit module provided by the <a href="https://devforum.roblox.com/t/3867553">VFX Forge</a> Roblox plugin.
|
|
11
|
+
|
|
12
|
+
## License
|
|
13
|
+
The emit module is licensed under a custom source-available copyleft license which **<mark>only allows usage within Roblox games</mark>**. That said, feel free to contribute and report bugs.
|
|
14
|
+
|
|
15
|
+
## Installation
|
|
16
|
+
|
|
17
|
+
#### Wally (Luau)
|
|
18
|
+
|
|
19
|
+
```sh
|
|
20
|
+
ForgeVFX = "zilibobi/forge-vfx@2.2.3"
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
#### npm (TypeScript)
|
|
24
|
+
|
|
25
|
+
```sh
|
|
26
|
+
npm i @zilibobi/forge-vfx@latest
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
#### Manual
|
|
30
|
+
|
|
31
|
+
Check the [releases page](https://github.com/zilibobi/forge-vfx/releases/latest) for prebuilt .rbxm files.
|
|
32
|
+
|
|
33
|
+
## Usage
|
|
34
|
+
|
|
35
|
+
The module needs to be initialized before emitting any effects.
|
|
36
|
+
After that it is also exposed inside `shared.vfx`.
|
|
37
|
+
|
|
38
|
+
```luau
|
|
39
|
+
local ReplicatedStorage = game:GetService("ReplicatedStorage")
|
|
40
|
+
|
|
41
|
+
local vfx = require(ReplicatedStorage.ForgeVFX)
|
|
42
|
+
|
|
43
|
+
vfx.init()
|
|
44
|
+
vfx.emit(workspace.Effect)
|
|
45
|
+
```
|
|
Binary file
|
package/out/index.d.ts
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Result returned from emitting VFX effects
|
|
3
|
+
*/
|
|
4
|
+
export interface EmitResult {
|
|
5
|
+
/**
|
|
6
|
+
* Promise that resolves when the effect has finished playing
|
|
7
|
+
*/
|
|
8
|
+
Finished: Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Initialize the Forge VFX system.
|
|
13
|
+
*/
|
|
14
|
+
export function init(): void;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Clean up and shut down the Forge VFX system.
|
|
18
|
+
* Destroys all caches and disconnects event handlers.
|
|
19
|
+
*/
|
|
20
|
+
export function deinit(): void;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Emit VFX effects from the provided instances.
|
|
24
|
+
* Supports ParticleEmitters, Beams, Trails, Models, and tagged effects.
|
|
25
|
+
* @param instances One or more Roblox instances to emit effects from
|
|
26
|
+
* @returns Result object with a Finished promise
|
|
27
|
+
*/
|
|
28
|
+
export function emit(...instances: Instance[]): EmitResult;
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Emit VFX effects with a scale multiplier.
|
|
32
|
+
* @param scale Scale multiplier for the effect
|
|
33
|
+
* @param instances One or more Roblox instances to emit effects from
|
|
34
|
+
* @returns Result object with a Finished promise
|
|
35
|
+
*/
|
|
36
|
+
export function emit(scale: number, ...instances: Instance[]): EmitResult;
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Emit VFX effects with a specific render depth.
|
|
40
|
+
* @param depth Render priority depth for the effect
|
|
41
|
+
* @param instances One or more Roblox instances to emit effects from
|
|
42
|
+
* @returns Result object with a Finished promise
|
|
43
|
+
*/
|
|
44
|
+
export function emitWithDepth(
|
|
45
|
+
depth: number,
|
|
46
|
+
...instances: Instance[]
|
|
47
|
+
): EmitResult;
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Enable a VFX instance.
|
|
51
|
+
* For ParticleEmitters and Beams, sets the Enabled property directly.
|
|
52
|
+
* For other instances, sets the "Enabled" attribute.
|
|
53
|
+
* @param obj The instance to enable
|
|
54
|
+
*/
|
|
55
|
+
export function enable(obj: Instance): void;
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Disable a VFX instance.
|
|
59
|
+
* For ParticleEmitters and Beams, sets the Enabled property directly.
|
|
60
|
+
* For other instances, sets the "Enabled" attribute.
|
|
61
|
+
* @param obj The instance to disable
|
|
62
|
+
*/
|
|
63
|
+
export function disable(obj: Instance): void;
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Cache attributes for a VFX instance and its descendants.
|
|
67
|
+
* Strips attributes from instances and stores them in memory for faster access.
|
|
68
|
+
* Only works on the client and for instances inside ReplicatedStorage.
|
|
69
|
+
* @param obj The instance whose descendant attributes to cache
|
|
70
|
+
*/
|
|
71
|
+
export function cacheAttributes(obj: Instance): void;
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Restore previously cached attributes back onto instances.
|
|
75
|
+
* Only works on the client.
|
|
76
|
+
* @param obj The instance whose descendant attributes to restore
|
|
77
|
+
*/
|
|
78
|
+
export function restoreAttributes(obj: Instance): void;
|
package/out/init.luau
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
return require(script.ForgeVFX)
|
package/package.json
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@zilibobi/forge-vfx",
|
|
3
|
+
"version": "2.2.3",
|
|
4
|
+
"description": "The official emit module from the VFX Forge plugin used to emit visual effects in-game.",
|
|
5
|
+
"main": "out/init.lua",
|
|
6
|
+
"types": "out/index.d.ts",
|
|
7
|
+
"type": "commonjs",
|
|
8
|
+
"files": [
|
|
9
|
+
"out"
|
|
10
|
+
],
|
|
11
|
+
"repository": {
|
|
12
|
+
"type": "git",
|
|
13
|
+
"url": "git+https://github.com/zilibobi/forge-vfx.git"
|
|
14
|
+
},
|
|
15
|
+
"homepage": "https://docs.zilibobi.dev/vfx-forge/module/installation/",
|
|
16
|
+
"author": "zilibobi",
|
|
17
|
+
"license": "VFX-DL-1.1",
|
|
18
|
+
"scripts": {
|
|
19
|
+
"typecheck": "tsc --noEmit",
|
|
20
|
+
"lint": "biome check index.d.ts",
|
|
21
|
+
"format": "biome format --write index.d.ts",
|
|
22
|
+
"format:check": "biome format index.d.ts"
|
|
23
|
+
},
|
|
24
|
+
"publishConfig": {
|
|
25
|
+
"access": "public"
|
|
26
|
+
},
|
|
27
|
+
"devDependencies": {
|
|
28
|
+
"@biomejs/biome": "^2.4.8",
|
|
29
|
+
"@rbxts/compiler-types": "^3.0.0-types.0",
|
|
30
|
+
"@rbxts/types": "^1.0.891",
|
|
31
|
+
"roblox-ts": "^3.0.0",
|
|
32
|
+
"typescript": "^5.9.3"
|
|
33
|
+
}
|
|
34
|
+
}
|