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



462
463
464
465
466
467
468
469
470
471
# File 'lib/box2d_types.rb', line 462

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



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

def customColor = self[:customColor]

#customColor=(v) ⇒ Object



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

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

#frictionObject



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

def friction = self[:friction]

#friction=(v) ⇒ Object



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

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

#restitutionObject



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

def restitution = self[:restitution]

#restitution=(v) ⇒ Object



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

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

#rollingResistanceObject



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

def rollingResistance = self[:rollingResistance]

#rollingResistance=(v) ⇒ Object



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

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

#tangentSpeedObject



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

def tangentSpeed = self[:tangentSpeed]

#tangentSpeed=(v) ⇒ Object



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

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

#userMaterialIdObject



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

def userMaterialId = self[:userMaterialId]

#userMaterialId=(v) ⇒ Object



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

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