Commit graph

50 commits

Author SHA1 Message Date
AzaezelX 4c083d713d physics findings
rigid: main finding is rigid needs to take delta into account for integration (aka interpolation)
also used POINT_EPSILON for thresholds for consistency

for rigidshape/item/player, main finding was length calcs for the search area were all over the place,
so we now derive the extended length of the cached area based on the velocity and the object's radius itself rather than guessin per class

atrest gravity calc suplimental syncing between rigidshape and vehicle

**remindernote POINT_EPSILO is 0.0001
2025-12-13 17:41:21 -06:00
AzaezelX cce40efd35 fix particle glow
multiple preloads were failing to return false or mesages on failure of mandatory entries.
clear out redundant isScriptFile definition
fix default order of /scripts/managedData script files
2025-11-13 14:29:25 -06:00
marauder2k7 ca1604170d initial commit
change the macro to use the refactor (exact same structure as the imageasset macro)
2025-06-19 13:34:07 +01:00
AzaezelX 618ddbc9ba Merge branch 'development' of https://github.com/TorqueGameEngines/Torque3D into aiSubsystem
# Conflicts:
#	Engine/source/T3D/player.cpp
2025-04-28 14:28:54 -05:00
AzaezelX 3210325f3f elevated mAicontroller to shapebase
aiwheeleedveiclecontrollerdata resolvespeed now only touches throttle
objects assigned aicontrollers now reflect that by thier objecttype
basic flocking
2025-04-19 04:25:36 -05:00
AzaezelX d36cf31707 more safeties. simplified reverse steering calc 2025-04-18 18:27:39 -05:00
AzaezelX 712404c9b4 hook up Vehicle's getAIMove(Move*);
list aiControllerData's in the datablock. though the command is still required to set the controler and look up the relevant db for game specific logic
2025-04-18 12:28:49 -05:00
AzaezelX 2d0bcbcf8d behavioural change: feeding an AInfo an object with a 0 radius causes the class to fill in radius from that objects bounds box
also, vehicle direct hooks
2025-04-18 11:36:27 -05:00
AzaezelX 5b2c0c7703 add a controlmap entry
for players, vehicles, and turret datablocks
add a client command to setMovemap(%object.getDatablock().controlMap)
2025-04-13 14:51:30 -05:00
AzaezelX fcd2d38deb further validator cleanups
bump default fidelity from 0,0001 to 0.01
fix F32Range. needs to go from - to +, not smallest to largest positive value
fix several misasigned validator ranges. most of which use some form of -1 default to do a Special Thing
2025-03-18 14:06:33 -05:00
Brian Roberts bab30568eb
Merge pull request #1409 from Azaezel/alpha41/soImpulsive
skip out on impulses that have no chance of moving the object
2025-03-14 13:59:44 -05:00
AzaezelX 325b3a97c0 skip out on impulses that have no chance of moving the object
also, sRestTol already is a 0.5 multiplier
2025-03-09 18:40:49 -05:00
AzaezelX f633ef3a3d fill in the validated variables 2025-03-09 11:53:23 -05:00
AzaezelX ccbcf7a862 take tick time into account as well. 2025-02-28 19:18:28 -06:00
AzaezelX c2b3ea6122 clean out redundant pack/unpack in vehicle 2025-02-28 18:35:46 -06:00
AzaezelX 43309fef2a rigidshape pef tweaks
account for integration for atrest evaluation. if we're atrest, *don't* network momentums. just send the bool
2025-02-28 17:54:20 -06:00
AzaezelX 7552554ded dial back overly agressive setRest 2024-02-01 17:47:30 -06:00
AzaezelX 3c7d2b1b6a physics notes
based on https://github.com/TorqueGameEngines/Torque3D/pull/1165 and after further talks with @AtomicWalrus:
use the massbox or bounds box based  mRigid.setObjectInertia method
to reduce recirulating, combine resolvecollision and resolvecontacts
clamp seperation force for contact resolution
gravity normalized to earth standard (9.8,not 20)
take delta-time into account *once* for kinetic energy vs gravity rest checks
and for debug purposes, expose mRigid.atRest to the inspector to see if it's truly at reast or grinding calcs to minimal effect
2023-12-28 21:04:16 -06:00
AzaezelX 0c97732ae9 cleanups for disablemove
downshift the exposure of the entry to rigidshape so it and vehicles all have the button.
fix moving them after they've become atrest failing to apply gravity untill collided with or applyimpulse is called on them
de-duplicate vehicle networking in reguards to rigid body instance variable transmission
2023-09-22 19:02:26 -05:00
AzaezelX f5a34308f9 add a docsURL; macro to link a given set of script config vars to git or similar storage urls via clicking on the inspector 2023-01-27 01:13:15 -06:00
AzaezelX ace18d0246 layout consistency pass pt 2 -place shapebase inheriting initpersistfields up top so the child layout appends to the parent 2023-01-24 19:30:09 -06:00
AzaezelX f07c8745b2 inspector cleanups
clustering work for datablocks for both consistent scanning for object parameters, as well as an eye towards orgainizing things to make reviewing what variations of components we'll be needing down the line clearer
2023-01-24 17:12:23 -06:00
AzaezelX 8821f62b0c misc fixes
utilize specialty case soundarray macros.
 slim duplicate entries in vehicle already hand;ed by rigidshape.
create a gamebasedata::onnewdatablock which calls onremove and onadd for the db for those classes like wheeledvehicle that expect mounting logic to occur
2022-12-27 21:10:15 -06:00
AzaezelX 93faa243ac cleanups for sound assets
removed redundant get<foo>Profile calls, correctly used a few in proxmine
2021-11-27 00:32:25 -06:00
AzaezelX 98a079a797 code duplication prune. should aid in stability 2021-10-03 02:56:26 -05:00
marauder2k7 6bec47d3fa -SoundAsset added init for enum types.
-Vehicles updated to use enum initpersistfield.
2021-09-28 23:36:04 +01:00
marauder2k7 e9d0f68b55 Preload all soundAsset
-Fixed: Preloads need to preload all soundAssets not just the ones it was preloading before.
2021-09-20 17:05:11 +01:00
marauder2k7 704eb27600 More Implements
-Most Vehicles and FX classes
-Vehicle classes may need more preloads for assets.
2021-09-20 13:07:50 +01:00
Areloch 5525f8ecdd Converts all game, gui editor, and system classes to utilize assets
Processed core, tools and default modules to utilize assets
Converted all console types that were string based, such as TypeImageFilename to utilize const char*/the string table, which avoids a lot of type swapping shenanigans and avoids string corruption
Removed unneeded MainEditor mockup module
Removed some unused/duplicate image assets from the tools
2021-07-19 01:07:08 -05:00
AzaezelX 516a05301f corrected and implemented a usage of shapeasset macros (and stray membervars touched). todo: shapebaseimage, debris. 2020-12-22 12:34:15 -06:00
AzaezelX 3a67ddd34c so ok, looks like there's *still* wonkiness with processtick runing through from vehicle to rigidshape. we'll have to review that at a later date. mean time, explicitly specifying shapebase so folks can proceede with thier project requests 2020-10-02 14:44:43 -05:00
AzaezelX afb39d398f code review:
1) got rid of evey class having it's own gravity
2) rigidshape inheritance simplifications
3) gravitymod from physicszones taking buoyancy into account natively (we still track raw bouyancy to cancel it out for player)
4) disableMove used throughout
5) items can now also be influenced by the appliedforce from physicszones
2020-10-02 13:53:46 -05:00
AzaezelX 245994dbdd Merge branch 'rigidshapeReorg' of https://github.com/Azaezel/Torque3D into alpha40_ReactiveRigidReorg
# Conflicts:
#	Engine/source/T3D/rigid.cpp
#	Engine/source/T3D/vehicles/vehicle.cpp
2020-01-22 05:33:47 -06:00
suncaller 31d0eb16f8 Clean up MSVC warning [C4312] conversion from type to type * of greater size 2019-02-02 23:09:55 -05:00
Azaezel f068664742 gamebase mmebervar cleanups. mPacked in particular is likely to geta followup for other cleaning. 2018-03-28 23:41:47 -05:00
Azaezel 77e9f3c6d4 CollisionState membervar clarification 2018-03-15 17:31:28 -05:00
Francisco Montañés García 2707eaf322 Apply Camera FX on vehicle driver position. 2017-05-02 17:17:33 +02:00
Azaezel 1ee127b753 more unused variable cleanups 2016-10-16 14:41:34 -05:00
OTHGMars 937b8830e1 Vehicle Mounting 2016-06-17 10:36:37 -05:00
Areloch 37e030f8f4 Makes vehicles work with the physics plugins.
Makes vehicles create a basic physics body when using one of the physics plugins so that they can collide with other physics-enabled objects.

Based on @rextimmy 's work.
2016-06-04 16:47:03 -05:00
Azaezel 0678817217 redundancy kill-off 2016-01-21 18:31:47 -06:00
Azaezel d6b6f36b0a rev 1 refactor for fitting rigidshape into the vehicle hierarchy.
cleaned a few, but by no means all redundancies.

DO NOTE THE FOLLOWING:

   ShapeBase::processTick(move);
    ShapeBase::interpolateTick(dt);

to avoid side effects for now. properly those would be retooled down the line to be more inheritance-friendly.
2016-01-21 18:14:15 -06:00
LuisAntonRebollo 4e9034854d Linux implementation. Include changes for gcc x64. 2015-01-24 22:08:26 +01:00
Thomas Fischer cd978039ac Merge pull request #635 from just-bank/engine-fixes
Various engine fixes
2014-05-23 14:09:00 +02:00
bank b2e6895554 Fix: preload() method on datablocks should always set errorStr when returning false.
Otherwise it will dump the previous error message (content of the errorStr).
2014-05-06 12:40:40 +04:00
cpusci 4c35fd37af Simple pass over the codebase to standardize the platform types. 2013-08-04 16:26:01 -05:00
Daniel Buckmaster b097c76eda Fixed stream read/write mismatch bug.
It was causing Vehicles to roll forwards with a constant velocity when
stationary, and ignore move->y.
2012-10-03 07:32:06 +10:00
Daniel Buckmaster e3cb30bb1d Added steering return to Vehicle.
It happens in Vehicle::updateMove so it can apply to all vehicle
subclasses. It is applied to both x and y steering.
2012-10-03 07:23:47 +10:00
Daniel Buckmaster eae9fc36e5 Added steering centre members to VehicleData.
steeringReturn is the main control for the amount of return in
the steering. Setting it to 0 (the default) disables steering return
completely.

steeringReturnSpeedScale is a multiplier on the amount of effect that
the vehicle's velocity has on its steering return.

powerSteering can be set to eliminate the effect of steering return on
user input. Without this flag set, the user will have a harder time
steering, because the wheels try to return as they steer. If this flag
is set, steering return will not be applied while the user is actually
steering, only when they release.
2012-10-02 21:02:42 +10:00
DavidWyand-GG 7dbfe6994d Engine directory for ticket #1 2012-09-19 11:15:01 -04:00