Skip to content

Spawns a fresh character, or uses existing pos to spawn the player.

Notifications You must be signed in to change notification settings

altv-crc/crc-spawn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

[CRC][TS] Spawn

Supported by CRC

Spawns a fresh character, or uses existing pos to spawn the player.

Requires

Highly recommended to get the extension, for better event handling.

Installation

  1. Create a folder in your src folder called crc-spawn.

  2. Add the TypeScript files from this resource, to that folder.

  3. Modify server.toml and ensure it loads whatever you named the folder.

In the case of the example above it should be crc-spawn.

resources = [ 
    ...
    'crc-spawn'
    ...
]

Your resource structure may vary

Developers

Spawning will auto synchronize a character to allow for crc to have data set against the character.

This means you can use the crc.data.setValue methods to update database data with any key / value pair.

Server Events

crc-spawn-new-spawn

Called when a pos in the document has never been set; and has been set for the first time.

alt.on('crc-spawn-new-spawn', (player: alt.Player) => {})

crc-spawn-spawned

Called for all spawn instances. Called immediately after a character has been spawned and synchronized.

alt.on('crc-spawn-spawned', (player: alt.Player) => {})

About

Spawns a fresh character, or uses existing pos to spawn the player.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published