Class: Box2D::SurfaceMaterial

Inherits:
FFI::Struct
  • Object
show all
Defined in:
lib/box2d_types.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.create_as(_friction_, _restitution_, _rollingResistance_, _tangentSpeed_, _userMaterialId_, _customColor_) ⇒ Object



483
484
485
486
487
488
489
490
491
492
# File 'lib/box2d_types.rb', line 483

def self.create_as(_friction_, _restitution_, _rollingResistance_, _tangentSpeed_, _userMaterialId_, _customColor_)
  instance = SurfaceMaterial.new
  instance[:friction] = _friction_
  instance[:restitution] = _restitution_
  instance[:rollingResistance] = _rollingResistance_
  instance[:tangentSpeed] = _tangentSpeed_
  instance[:userMaterialId] = _userMaterialId_
  instance[:customColor] = _customColor_
  instance
end

Instance Method Details

#customColorObject



481
# File 'lib/box2d_types.rb', line 481

def customColor = self[:customColor]

#customColor=(v) ⇒ Object



482
# File 'lib/box2d_types.rb', line 482

def customColor=(v) self[:customColor] = v end

#frictionObject



471
# File 'lib/box2d_types.rb', line 471

def friction = self[:friction]

#friction=(v) ⇒ Object



472
# File 'lib/box2d_types.rb', line 472

def friction=(v) self[:friction] = v end

#restitutionObject



473
# File 'lib/box2d_types.rb', line 473

def restitution = self[:restitution]

#restitution=(v) ⇒ Object



474
# File 'lib/box2d_types.rb', line 474

def restitution=(v) self[:restitution] = v end

#rollingResistanceObject



475
# File 'lib/box2d_types.rb', line 475

def rollingResistance = self[:rollingResistance]

#rollingResistance=(v) ⇒ Object



476
# File 'lib/box2d_types.rb', line 476

def rollingResistance=(v) self[:rollingResistance] = v end

#tangentSpeedObject



477
# File 'lib/box2d_types.rb', line 477

def tangentSpeed = self[:tangentSpeed]

#tangentSpeed=(v) ⇒ Object



478
# File 'lib/box2d_types.rb', line 478

def tangentSpeed=(v) self[:tangentSpeed] = v end

#userMaterialIdObject



479
# File 'lib/box2d_types.rb', line 479

def userMaterialId = self[:userMaterialId]

#userMaterialId=(v) ⇒ Object



480
# File 'lib/box2d_types.rb', line 480

def userMaterialId=(v) self[:userMaterialId] = v end