3 yrs ago:
https://forum.thegamecreators.com/thread/216508
Otherwise, only bugged when setting CanRotate to 0 (,1 retains previous Mass setting):
SetErrorMode(2)
// set window properties
SetWindowTitle( "SpriteMass" )
SetWindowSize( 1080, 720, 0 )
SetWindowAllowResize( 1 ) // allow the user to resize the window
// set display properties
SetVirtualResolution( 1080, 720 ) // doesn't have to match the window
SetOrientationAllowed( 1, 1, 1, 1 ) // allow both portrait and landscape on mobile devices
SetSyncRate( 30, 0 ) // 30fps instead of 60 to save battery
SetScissor( 0,0,0,0 ) // use the maximum available screen space, no black borders
UseNewDefaultFonts( 1 ) // since version 2.0.22 we can use nicer default fonts
This = CreateSprite(0)
SetSpriteColor(This,255,0,0,255)
SetSpritePosition(This,440,620)
SetSpriteSize(This,100,100)
SetSpritePhysicsOn(This,2)
SetSpritePhysicsMass(This,20)
SetSpritePhysicsCanRotate(This,0)
That = CreateSprite(0)
SetSpriteColor(That,0,255,0,255)
SetSpriteSize(That,100,100)
SetSpritePosition(That,540,620)
SetSpritePhysicsOn(That,2)
SetSpritePhysicsCanRotate(That,0)
SetSpritePhysicsMass(That,20)
ThisMass = CreateText("Mass: "+STR(GetSpritePhysicsMass(This)))
SetTextSize(ThisMass,32)
SetTextColor(ThisMass,255,0,0,255)
ThatMass = CreateText("Mass: "+STR(GetSpritePhysicsMass(That)))
SetTextSize(ThatMass,32)
SetTextColor(ThatMass,0,255,0,255)
SetTextPosition(ThatMass,0,32)
do
SetSpritePhysicsVelocity(This,100,0)
SetSpritePhysicsVelocity(That,-100,0)
Sync()
loop