Class: Bayonetta::CLHFile::ClothAT

Inherits:
LibBin::Structure
  • Object
show all
Defined in:
lib/bayonetta/clh.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.from_bxm_cloth_at(c) ⇒ Object



41
42
43
44
45
# File 'lib/bayonetta/clh.rb', line 41

def self.from_bxm_cloth_at(c)
  clat = self::new
  clat.from_bxm_cloth_at(c)
  clat
end

Instance Method Details

#from_bxm_cloth_at(h) ⇒ Object



31
32
33
34
35
36
37
38
39
# File 'lib/bayonetta/clh.rb', line 31

def from_bxm_cloth_at(h)
  @p1 = h.at_css("p1").content.to_i
  @p2 = h.at_css("p2").content.to_i
  @weight = h.at_css("weight").content.to_f
  @radius = h.at_css("radius").content.to_f
  @offset1 = FVector.from_bxm_vector(h.at_css("offset1").content)
  @offset2 = FVector.from_bxm_vector(h.at_css("offset2").content)
  self
end

#remap(map) ⇒ Object



47
48
49
50
# File 'lib/bayonetta/clh.rb', line 47

def remap(map)
  @p1 = check_and_remap_bone(map, @p1)
  @p2 = check_and_remap_bone(map, @p2)
end