Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update NetworkAddEntityToSynchronisedScene.md #829

Closed
wants to merge 5 commits into from

Conversation

Majeranek777
Copy link

Here you go


## Animation Dictionaries
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have to use triple hashes for this, otherwise there will be compile errors.
For example:

### Animation Dictionaries

* Most can be found here: (Gta V path)\update\x64\dlcpacks\(Desired folder like mpheist)\dlc.rpf\x64\anim\ingame\clip_anim@.rpf\
* Most usefull ones start with anim@scripted@...

## Animations
Copy link
Contributor

@4mmonium 4mmonium Jun 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use triple hashes for this too: ### Animations

* **Animation List**: https://alexguirre.github.io/animations-list/
* **Other Option**: You are much more likely to find the animation by opening [CodeWalker's](https://pl.gta5-mods.com/tools/codewalker-gtav-interactive-3d-map) Ped Viewer and putting the AnimDict into the search bar.

## Used With
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Triple hashes for this as well. ### Used With

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, will change that

@@ -5,16 +5,42 @@ ns: NETWORK

```c
// 0xF2404D68CBC855FA 0x10DD636C
void NETWORK_ADD_ENTITY_TO_SYNCHRONISED_SCENE(Entity entity, int netScene, char* animDict, char* animName, float speed, float speedMulitiplier, int flag);
void NETWORK_ADD_ENTITY_TO_SYNCHRONISED_SCENE(Entity entity, int netScene, char* animDict, char* animName, float blendInSpeed, float blendOutSpeed, float flag);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I cannot find any evidence of the flag being a float value, I will explain down below in the ## Parameters section

* **speed**:
* **speedMulitiplier**:
* **flag**:
### Parameters
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Things such as ## Parameters and ## Example don't need triple hashes, only custom headers do. Custom headers in this case are ### Animation Dictionaries, ### Animations, ### Used With. Basically any headers that you add that aren't commonly used in native docs.

* **animName**: The name of the animation that the entity is gonna play.
* **blendInSpeed**: a float (normal speed is 8.0f).
* **blendOutSpeed**: a float (normal speed is -8.0f).
* **flag**: A float 1000.0f (Also doesn't seem to affect anything).
Copy link
Contributor

@4mmonium 4mmonium Jun 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From my research of this native method, flag is still an int.

If blendInSpeed is lesser or equal to 0.0, it's forced by the game to an ieee-754 value of 1000.0 (float).

If blendOutSpeed is greater or equal to 0.0, the game forces the value to -1000.0 (float).
So judging by this, blendInSpeed should be greater than 0.0 and blendOutSpeed lower.

You can find more about the ieee-754 specification here.

* **NetworkAddEntityToSynchronisedScene**: https://docs.fivem.net/natives/?_0xF2404D68CBC855FA.
* **NetworkCreateSynchronisedScene**: https://docs.fivem.net/natives/?_0x7CD6BC4C2BBDD526.

### Example
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't need triple hashes, only custom headers do, you can use double hashes here 🙂

@4mmonium 4mmonium added the abandoned Abandoned by Author label Nov 27, 2023
@4mmonium
Copy link
Contributor

4mmonium commented Nov 29, 2023

Hi, just checking in, are there any updates regarding the changes I requested?
Marked this as abandoned since we haven't heard from you since my last review.
Thank you so much 🙂

Corrected the PR so it's in the correct format at least. I believe any links linking off-site will probably need to be removed since they they can go offline in the long run.
Correct 'Used With' native references.
@4mmonium
Copy link
Contributor

4mmonium commented Dec 3, 2023

Update: Made some corrections to your PR. Still marked as abandoned though.
Thanks!

Centralize animation list and correct some examples so this can be merged.
Copy link
Contributor

@PsychoShock PsychoShock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even though it's abandoned, a description of the native can be added: Integrates a non-pedestrian entity along with its corresponding animation data into a previously established network-synchronized scene.

Also a lot have been made here, maybe a squash would be appreciate by Ammonium

@freedy69
Copy link
Contributor

Update: Made some corrections to your PR. Still marked as abandoned though.

Thanks!

Should this pr be closed? Since a commit that updated network synchronized scene natives was made a few days ago

@4mmonium
Copy link
Contributor

Hi, this has been superseded by the following commit, thank you for your contribution nonetheless! 😊

@4mmonium 4mmonium closed this Apr 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
abandoned Abandoned by Author
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants