randzhamiya Posted August 6, 2020 Share Posted August 6, 2020 entityModelChange(entity, oldModel) how to trigger this events give an example Link to comment Share on other sites More sharing options...
Zepenthium Posted August 6, 2020 Share Posted August 6, 2020 (edited) As example: player.model = mp.joaat('player_zero') Will trigger this event: [ServerEvent(Event.EntityModelChange)] public void OnEntityModelChange(NetHandle entityHandle, uint oldModel) { switch (entityHandle.Type) { case EntityType.Player: { var player = entityHandle.Entity<Client>(); player.SendChatMessage($"Your model has changed from {oldModel} to {player.Model}!"); break; } // and so on.. } } It's a C# server-side example. Source: gtanet wiki, ragemp wiki Zepenthium~ Edited August 6, 2020 by Zepenthium Link to comment Share on other sites More sharing options...
randzhamiya Posted August 7, 2020 Author Share Posted August 7, 2020 В 06.08.2020 в 07:00, Zepenthium сказал: As example: player.model = mp.joaat('player_zero') Will trigger this event: [ServerEvent(Event.EntityModelChange)] public void OnEntityModelChange(NetHandle entityHandle, uint oldModel) { switch (entityHandle.Type) { case EntityType.Player: { var player = entityHandle.Entity<Client>(); player.SendChatMessage($"Your model has changed from {oldModel} to {player.Model}!"); break; } // and so on.. } } It's a C# server-side example. Source: gtanet wiki, ragemp wiki Zepenthium~ can you show an example on node.js? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now