coolman Posted December 17, 2011 Share Posted December 17, 2011 Hey, I have been trying to find a solution to fix that problem and I can't. Maybe you know. function checkStreamIn() local x, y, z = getElementPosition( getLocalPlayer() ) local playerdimension = getElementDimension ( getLocalPlayer() ) streamdistance = 5 for key, this in pairs( getElementsByType( "vehicle" ) ) do local vx, vy, vz = getElementPosition( this ) setElementStreamable ( this, true ) if getDistanceBetweenPoints3D( vx, vy, vz, x, y, z ) < streamdistance then setElementStreamable ( this, true ) else success = setElementStreamable ( this, false ) end end end setTimer(checkStreamIn, 1000, 0) success return always TRUE and elements are still visible. Link to comment
Castillo Posted December 17, 2011 Share Posted December 17, 2011 This code seems to be cut from this resource: https://community.multitheftauto.com/index.php?p= ... ls&id=1030 Why don't you use it all instead of taking a part of it? Link to comment
coolman Posted December 17, 2011 Author Share Posted December 17, 2011 This code seems to be cut from this resource: https://community.multitheftauto.com/index.php?p= ... ls&id=1030Why don't you use it all instead of taking a part of it? This resource has bug. We talk about pasted code. Link to comment
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