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



477
478
479
480
481
482
483
484
485
486
# File 'lib/box2d_types.rb', line 477

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



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

def customColor = self[:customColor]

#customColor=(v) ⇒ Object



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

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

#frictionObject



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

def friction = self[:friction]

#friction=(v) ⇒ Object



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

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

#restitutionObject



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

def restitution = self[:restitution]

#restitution=(v) ⇒ Object



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

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

#rollingResistanceObject



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

def rollingResistance = self[:rollingResistance]

#rollingResistance=(v) ⇒ Object



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

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

#tangentSpeedObject



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

def tangentSpeed = self[:tangentSpeed]

#tangentSpeed=(v) ⇒ Object



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

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

#userMaterialIdObject



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

def userMaterialId = self[:userMaterialId]

#userMaterialId=(v) ⇒ Object



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

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