Jump to content

CrosRoad95

Members
  • Posts

    128
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by CrosRoad95

  1. > Game freezes if you tab out and in too quickly, not sure if its a general issue but I dont have it on official client. known bug, https://github.com/multitheftauto/mtasa-blue/issues/1103 BUT! bp could increase frequency of occurring. Apart of that, patch has been pushed that prevents rendering debug wireframe while game minimalized Be sure you downloaded latest build!
  2. I want to remaind everyone this topic. If you tested it please let me know in the comment, if your game crashed please let me know as well thanks in advance.
  3. Fixed few crashes, still waiting for people who willing to help me with testing Don't forget to download updated build: https://github.com/multitheftauto/mtasa-blue/suites/6097623305/artifacts/211522093
  4. I need your help! After long time, long discussion with other contributors what initial release should containi spent a lot of time polishing, fixing bullet physics feature people first would see almost 3 years ago. Meanwhile API got limited to bere usable minimum to limit points of failure, all cool features i was showing got moved to different branch as a reference for future updates. Whole logic got moved to "shared" section to let you use all of it's feature both client and server side! Core devs are busy, pull request is HUGE and nice to give them tested, cleaned up code they can review and because it is not a trivial task testing even limited amount of feature i need your help If you have some free time, and minimum lua/mta experience you can download latest build of mta, client and server and test it yourself, maybe you find an issue i was unable to spot? Download newest custom build of mta with bullet physics at https://github.com/multitheftauto/mtasa-blue/suites/6176759056/artifacts/216790429 Download test resource ( if you want ), v1: https://github.com/multitheftauto/mtasa-blue/files/8459389/tests.v1.zip it should yield a result the same as on the video below. Documentation: All availiable both client and server side except "physicsDrawDebug" Bullet physics functions: physics-shape-box physicsCreateBoxShape( float xyzSize ) -- creates cube of given dimensions, 1 means 1x1x1. physics-shape-box physicsCreateBoxShape( float x, float y, float y ) -- creates box of given dimensions. physics-rigid-body physicsCreateRigidBody(physics-shape, float x, float y, float z [, float rx, float ry, float rz [, table options ] ] ) -- spawns rigid body from given shape at given position and rotation with options: -- "mass" - float between 1.0 to 1000000.0, default: 1.0 -- "localIntertia" - vector, default: 0,0,0 -- "centerOfMass" - vector, default: 0,0,0 physics-static-collision physicsCreateStaticCollision(physics-shape, float x, float y, float z [, float rx, float ry, float rz ]) -- spawns static collision at given position and rotation. table physicsGetDebugLines( float x, float y, float z, float radius ) -- returns table of lines in format { fromX, fromY, fromZ, toX, toY, toZ, color } of all collisions in given radius - mostly used to debug server side physics. bool physicsDrawDebug() -- draws debug collision in 500 meters radius, availiable only client side, use in onClientRender event. bool isPhysicsElement( physics-element physicsElement ) -- isElement equivalent for physics elements Extended functionality: setElementPosition, setElementRotation, getElementPosition, getElementRotation -- accepting physics-world-element as first parameter setElementVelocity, setElementAngularVelocity, getElementVelocity, getElementAngularVelocity -- accepting physics-rigid-body as first parameter destroyElement -- accepting physics-element Bullet physics introduces new user-data / element types ( they are not acctual elements like vehicle, player ). Used lighter version of elements to increate overall performance, simillar to how "setTimer" return timer handle, functions above return simillar handle. New user-data/elements types and it's hierarchy: Default, current physics settings: Gravity: 0.0, 0.0, -10.0 Simulation step: fps independent, 10 substeps Fixed time step: 1.0 / 60.0 Other useful informations: 1. One shape can ( should ) be used in many rigid bodies, static collisions ( in future as a part of compound shape ) 2. Spawning many rigid bodies at one position will lead to high memory usage. 3. If you destroy shape, all referenced rigid bodies and static collision will be removed as well - removing static collision or rigid body never removes shape 4. Physics is frame indendent and not perfectly deterministic. 5. Yellow/White wireframe indicate active rigid body, blue are "about to sleep", green are sleeping. Sleeping rigid body behave like static collision until get hit, reactivated ( changing position, applying forces activates body, in future i have a plan to introduce function to wake up them on demand ) 6. Physics elements created server or client side are not synced at all. You have to do this manually but in plan is to add build in customizable synchronization. Pull request: https://github.com/multitheftauto/mtasa-blue/pull/1246 Read more about bullet physics: https://github.com/bulletphysics/bullet3 https://pybullet.org/wordpress/ More at mta dev discord: https://discord.gg/GNN6PRtTnu Do you have any idea of physics applications in mta? Let us know in the comment down below! Thanks in advance for help! Patch 19.04.2022 - "getUserdataType" now returns exact shape type not only general shape type - clientside draw debug no longer render debug when game minimalized. Download newest custom build of mta with bullet physics at https://github.com/multitheftauto/mtasa-blue/suites/6176759056/artifacts/216790429
  5. -link hidden- you sure you should get be unbanned? By asking for help to spoof serial? Merhaba multi theft auto mta adlı oyundan global ban yedim 32 haneli serial numarasına ban atıyor volume id falan filan herşeyi denedim internetteki genede kaldıramadım forumdaki spoofer bu banı kaldırıyormu ban atılan donanımı şöyle paylaşayım : FF015150BFD7107EC2C2DB1C924A6FF4 32 haneli bir serial numarası ne yaptyısam kaldıramadım forumdaki hwid spoofer kaldırırmı kaldıramazsa nasıl kaldırabilirim bu banı
  6. i found github action for v8 compilation, so one problem solved https://github.com/CrosRoad95/v8-builder/runs/3966953233?check_suite_focus=true now i copy artifacts to mta, and we are in home
  7. You can append custom data at the end of dff/col/txd files, you can add option to add extra information about author of model ( encrypted to look simillar to rest of file ), if someone manage to steal models - you can still track who originally entrypted them
  8. https://github.com/multitheftauto/mtasa-blue/pull/2169 draft pull request created
  9. I have better idea: once per year your first time ban will "warning" 1 hour long ban. Sometimes you can really forget to turn off some specific programs and get by accident banned.
  10. Some benchmark: Javascript ( with some debug informations ), two times slower than c++ Lua ( requires debughook to do not get terminated due infinity loop protection ) Js is faster in this case because "add" function was called simillar each time, calling same function with different arguments ( mostly different types ) may cause performance to degradate ( Jitted functions get deoptimized )
  11. Few days ago i started discussion about javascript in mta, for more details checkout https://github.com/multitheftauto/mtasa-blue/discussions/2008 I'm waiting for opinions, suggestions, and everything what can help, here, on at github I already made working "hello world" example
  12. I back to work on BP! I Successfully added support for multithreading, so simulation will work smooth until you get crazy. Also set of function get changed, old function has changed and new get added. Here's current progress:
  13. you did mistake, 2020 - 2005 is equal 15 but not 16
  14. https://community.multitheftauto.com/index.php?p=resources&s=details&id=18042 compiled script https://community.multitheftauto.com/index.php?p=resources&s=details&id=18032 and another compiled
  15. i started to document functions here https://wiki.multitheftauto.com/wiki/PhysicsCreateWorld and pull request here https://github.com/multitheftauto/mtasa-blue/pull/1246 i'm waiting for feedback about syntax
  16. for now project is frozen until first set of rendering functions will released
  17. For long time i considered to do something with physics in mta. For now doing even simplest things such falling box, tree on flat area looks cartoonish. In my history of i saw few attempts of doing simple physics, mostly it was in closed area without bigger interactions with poor performance due you just can't calculate collision in other way than processLineOfSight, isLineOfSightClear or read directly .col file as Tederis did. I started with something to render things, thats how FBX https://github.com/multitheftauto/mtasa-blue/pull/1093 to bypass default rendering to handle future i'll introduce in future. That's how bullet physics project born, first idea how to use react physics, works simillar but is lighter and general smaller project but 0x416c69 suggested to use bullet. I'll use this topic also to prepare long list of features it contains for future copy paste to PR and wiki page The main assumption is to allow for create multiple world with completly independed simulations, get and set detailed information about current step of simulation, fully control how everything is simulated, quality of collision tests, speed and a lot more. i'm trying keep amount of functions low, because if that most stuff is packed into one function. Syntax and name of some function might change in future or along suggestions. Not all properties supports every physics element, some are only get, other set only, however most of them are set/get Current stage: I already implemented function such a: physics physicsCreateWorld() - responsible for creating new world for simulations, return element which will use later. physics-rigidbody physicsCreateRigidBody( shape-type, mixed arguments ) - creates rigid body which is use to simulation bahaviour of non-static shapes, collisions ( currently only few models in mta can do this in simple way ). physics-rigidbody physicsCreateRigidBodyFromModel( model ) - used to create rigid body directly from collision data taken from gta model. physics-static-collision physicsCreateStaticCollision( shape-type, mixed arguments ) - creates static collision which will not move at all ( it is still possible to move it by Lua script ) physics-shape physicsAddShape( shape-type, mixed arguments ) - if you create compound shape, this function let you add more shapes into static collision or rigid body bool physicsSetProperties( any physics element, physics-property, mixed arguments ) - main function to control physics, rigid bodies, static collisions, shapes. Works in simillar way as handling functions. mixed physicsGetProperties( any physics element, physics-property ) - same as above, but getting properties bool physicsDrawDebug( physics ) - use to visualization of world, must be used in render function bool physicsSetDebugMode( physics-debug-mode, enabled ) - use to turn off/on debugging features bool physicsBuildCollisionFromGTA( physics ) - used to create static collisions in specified world from original collisions, doesn't create whole world instantly, require to move player around world to load collision data. physics-constraint physicsCreateConstraint( physics, physics-rigid-body, physics-rigid-body, constraint-type, mixed arguments ) - use to connecting two or more rigid bodies into one entity bool physicsApplyForce( physics-rigid-body, vector from, vector to ) - pushing rigid body in particular point you choosed. bool physicsApplyCentralForce( physics-rigid-body, vector direction ) - apply force from central position of rigid, it's more like "accelereate", should be used more than once at the some period of time bool physicsApplyCentralImpulse( physics-rigid-body, vector direction ) - setting position from center of rigid bool physicsApplyDamping( physics-rigid-body, float force ) - i'm not sure, but it should slow down velocity and rotation of model by specified amount of units physicsApplyImpulse( physics-rigid-body, vector direction ) - i'm not sure how it works physicsApplyTorque( physics-rigid-body, vector rotation ) - same as physicsApplyCentralForce but for rotation physicsApplyTorqueImpulse( physics-rigid-body, vector rotation ) - setting rotation speed physics-properties: "mass", "position" ,"rotation", "sleepingthresholds", "restitution", "scale" "debugcolor", "filtermask", "filtergroup", "stiffness" `sleepingthresholds` means how slow rigid must move/rotate to sleep, it makes stops moving at all but still can be pushed by other rigids `restitution` bounciness, between 0-1 but accept any value above `stiffness` - for fixed constraint `filtermask` i still figuring out how it work, but should let you use 32 bit mask to set which rigid with which should collide Bullet documentation: https://github.com/bulletphysics/bullet3/blob/master/docs/Bullet_User_Manual.pdf page 13 contains useful information when which shape should be used physics-constraints: "pointtopoint", "hidge", "fixed", "slider" Physics-shapes: "box", "sphere", "capsule", "cone", "cylinder", "heightfieldterrain", "compound", "trianglemesh", "convexhull" `compound` is used for constructing rigid made of various shapes Plans for future: "heightfieldterrain" shape type accept black-white texture for faster creation Support for cloths, soft bodies Media: Videos are availiable at my youtube channel https://www.youtube.com/channel/UC95MpsQ1JppDNpMvl_7c1rg screenshots and gifs of current progress: Documentation i use: https://pybullet.org/Bullet/BulletFull I'm waiting for your suggestions Topic not finishedd
  18. That mean s0beit will work?
×
×
  • Create New...