Skip to content

Commit

Permalink
fix: object streaming article (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
xxshady authored Apr 10, 2024
1 parent 8512b04 commit 03db8bd
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions articles/tutorials/stream_objects.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@ Just throw the dlc.rpf as resource (available since [v15](https://docs.altv.mp/a
```
.
├── resources/
│ └── altvlogo/
│ └── <your name>/
│ └── dlc.rpf
└── server.toml
```

> [!NOTE]
> `resource.toml` is not even needed!
Add "meteor" resource to `resources` in `server.toml` like this:
Add your resource to `resources` in `server.toml` like this:

```toml
resources = [
"altvlogo",
"<your resource name>",
# other resources...
]
```
Expand Down Expand Up @@ -95,9 +95,9 @@ Add the `altvlogo` (folder name is your resource name) to the `server.toml` file
To spawn the object now, use the following snippet:

```js
async function spawnLogo() {
const modelHash = alt.hash("tw_altv_logo");
await alt.Utils.requestModel(modelHash);
native.createObject(modelHash, 0, 0, 100, false, false, false);
}
import alt from 'alt-client';

const pos = new alt.Vector3(0, 3, 72);
const rot = alt.Vector3.zero;
new alt.LocalObject('tw_altv_logo', pos, rot);
```

0 comments on commit 03db8bd

Please sign in to comment.