Jump to content

Projectile filter.


bandi94

Recommended Posts

Posted

Is there any way to filter the normal rocket (lunched by hunter in DM map) from Heat Seeking rocket (created by my script).

I know one way would be to add my rocket's to a table wen i create them , but it's not the best way , bk i would need to send it to the server , proccess them , and send the tabel back to all client's. It would be horible to send one table from each client, then each client would get 24 table on every Frame......

getElementsByType("Projectile") - would return both type's after that is there any way to filter them ??

THX

Ingame Name : |DGT|Puma

DGT Clan Server 24/7 Owner/Scripter

MultiGameMode in progress :

n-560x95_FFFFFF_FFFFFF_0283C4_000000.png

  • Moderators
Posted

https://wiki.multitheftauto.com/wiki/GetProjectileType

addEventHandler ( "onClientProjectileCreation", root, 
function( creator ) 
    local projType = getProjectileType(source) 
end) 

Do you want to improve your Lua programming skills and make less mistakes?   Start with Lua Language Server!   🙀

 

  Useful functions  3x 

  Tutorials  4x 

 

  • Moderators
Posted
bk i would need to send it to the server , proccess them , and send the tabel back to all client's.

Change them to strings, it is the only way to secure their passages.

I am not sure if you create a projectile and the projectile that I see on my screen contains the same userdata.

Do you want to improve your Lua programming skills and make less mistakes?   Start with Lua Language Server!   🙀

 

  Useful functions  3x 

  Tutorials  4x 

 

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...