Cloth.smali

.class public Lcom/censivn/C3DEngine/effects/modifiers/Cloth;
.super Lcom/censivn/C3DEngine/effects/core/Modifier;
.source "Cloth.java"

# interfaces
.implements Lcom/censivn/C3DEngine/effects/IEffects;


# instance fields
.field private _boundsMaxX:F

.field private _boundsMaxY:F

.field private _boundsMaxZ:F

.field private _boundsMinX:F

.field private _boundsMinY:F

.field private _boundsMinZ:F

.field private _connections:Ljava/util/ArrayList;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/ArrayList",
            "<",
            "Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;",
            ">;"
        }
    .end annotation
.end field

.field private _forceX:F

.field private _forceY:F

.field private _forceZ:F

.field private _friction:F

.field private _rigidity:F

.field private _useBounds:Z

.field private _vertices:Ljava/util/ArrayList;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/ArrayList",
            "<",
            "Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;",
            ">;"
        }
    .end annotation
.end field


# direct methods
.method public constructor <init>()V
    .registers 3

    .prologue
    .line 44
    const/high16 v0, 0x3f800000    # 1.0f

    const/4 v1, 0x0

    invoke-direct {p0, v0, v1}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;-><init>(FF)V

    .line 45
    return-void
.end method

.method public constructor <init>(FF)V
    .registers 4

    .prologue
    const/4 v0, 0x0

    .line 36
    invoke-direct {p0}, Lcom/censivn/C3DEngine/effects/core/Modifier;-><init>()V

    .line 18
    iput v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceX:F

    .line 19
    iput v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceY:F

    .line 20
    iput v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceZ:F

    .line 38
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_rigidity:F

    .line 39
    invoke-virtual {p0, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->setFriction(F)V

    .line 40
    return-void
.end method

.method private createConnection(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;)V
    .registers 6

    .prologue
    .line 469
    invoke-virtual {p1, p2}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->distanceTo(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;)F

    move-result v0

    .line 470
    new-instance v1, Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;

    iget v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_rigidity:F

    invoke-direct {v1, p1, p2, v0, v2}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;-><init>(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;FF)V

    .line 472
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_connections:Ljava/util/ArrayList;

    invoke-virtual {v0, v1}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    .line 473
    return-void
.end method

.method private initVerletConnections()V
    .registers 10

    .prologue
    const/4 v2, 0x0

    .line 440
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getFaces()Ljava/util/ArrayList;

    move-result-object v4

    .line 442
    invoke-virtual {v4}, Ljava/util/ArrayList;->size()I

    move-result v5

    .line 446
    new-instance v0, Ljava/util/ArrayList;

    invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V

    iput-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_connections:Ljava/util/ArrayList;

    move v1, v2

    .line 448
    :goto_13
    if-ge v1, v5, :cond_7c

    .line 449
    invoke-virtual {v4, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/FaceProxy;

    .line 450
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/FaceProxy;->getVertices()Ljava/util/ArrayList;

    move-result-object v6

    .line 451
    invoke-virtual {v6}, Ljava/util/ArrayList;->size()I

    move-result v7

    move v3, v2

    .line 453
    :goto_24
    add-int/lit8 v0, v7, -0x1

    if-ge v3, v0, :cond_5f

    .line 455
    invoke-virtual {v6, v3}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->getVerletVertexProxy()Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    move-result-object v8

    add-int/lit8 v0, v3, 0x1

    invoke-virtual {v6, v0}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->getVerletVertexProxy()Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    move-result-object v0

    invoke-direct {p0, v8, v0}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->createConnection(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;)V

    .line 457
    const/4 v0, 0x1

    if-le v3, v0, :cond_5b

    .line 458
    invoke-virtual {v6, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->getVerletVertexProxy()Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    move-result-object v8

    invoke-virtual {v6, v3}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->getVerletVertexProxy()Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    move-result-object v0

    invoke-direct {p0, v8, v0}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->createConnection(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;)V

    .line 453
    :cond_5b
    add-int/lit8 v0, v3, 0x1

    move v3, v0

    goto :goto_24

    .line 462
    :cond_5f
    add-int/lit8 v0, v7, -0x1

    invoke-virtual {v6, v0}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->getVerletVertexProxy()Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    move-result-object v3

    invoke-virtual {v6, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->getVerletVertexProxy()Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    move-result-object v0

    invoke-direct {p0, v3, v0}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->createConnection(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;)V

    .line 448
    add-int/lit8 v0, v1, 0x1

    move v1, v0

    goto :goto_13

    .line 466
    :cond_7c
    return-void
.end method

.method private initVerletVertices()V
    .registers 6

    .prologue
    .line 415
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getVertices()Ljava/util/ArrayList;

    move-result-object v2

    .line 416
    invoke-virtual {v2}, Ljava/util/ArrayList;->size()I

    move-result v3

    .line 420
    new-instance v0, Ljava/util/ArrayList;

    invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V

    iput-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    .line 422
    const/4 v0, 0x0

    move v1, v0

    :goto_13
    if-ge v1, v3, :cond_2c

    .line 424
    invoke-virtual {v2, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/VertexProxy;

    .line 425
    new-instance v4, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    invoke-direct {v4, v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;-><init>(Lcom/censivn/C3DEngine/effects/core/VertexProxy;)V

    .line 426
    invoke-virtual {v0, v4}, Lcom/censivn/C3DEngine/effects/core/VertexProxy;->setVerletVertexProxy(Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;)V

    .line 427
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0, v4}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    .line 422
    add-int/lit8 v0, v1, 0x1

    move v1, v0

    goto :goto_13

    .line 436
    :cond_2c
    return-void
.end method

.method private lockSet(FLjava/lang/String;FI)V
    .registers 10

    .prologue
    const/4 v3, 0x0

    .line 312
    .line 313
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->size()I

    move-result v4

    move v2, v3

    .line 317
    :goto_8
    if-ge v2, v4, :cond_51

    .line 319
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    .line 321
    const-string/jumbo v1, "x"

    invoke-virtual {p2, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_3e

    .line 322
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getX()F

    move-result v1

    .line 329
    :goto_1f
    sub-float/2addr v1, p1

    invoke-static {v1}, Ljava/lang/Math;->abs(F)F

    move-result v1

    cmpg-float v1, v1, p3

    if-gtz v1, :cond_3a

    .line 330
    and-int/lit8 v1, p4, 0x1

    if-eqz v1, :cond_2e

    .line 331
    iput-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileX:Z

    .line 332
    :cond_2e
    and-int/lit8 v1, p4, 0x2

    if-eqz v1, :cond_34

    .line 333
    iput-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileY:Z

    .line 334
    :cond_34
    and-int/lit8 v1, p4, 0x4

    if-eqz v1, :cond_3a

    .line 335
    iput-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileZ:Z

    .line 317
    :cond_3a
    add-int/lit8 v0, v2, 0x1

    move v2, v0

    goto :goto_8

    .line 323
    :cond_3e
    const-string/jumbo v1, "y"

    invoke-virtual {p2, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_4c

    .line 324
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getY()F

    move-result v1

    goto :goto_1f

    .line 326
    :cond_4c
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getZ()F

    move-result v1

    goto :goto_1f

    .line 339
    :cond_51
    return-void
.end method


# virtual methods
.method public apply()V
    .registers 6

    .prologue
    const/4 v1, 0x0

    .line 356
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_connections:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->size()I

    move-result v3

    move v2, v1

    .line 358
    :goto_8
    if-ge v2, v3, :cond_19

    .line 360
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_connections:Ljava/util/ArrayList;

    invoke-virtual {v0, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;

    .line 361
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;->update()V

    .line 358
    add-int/lit8 v0, v2, 0x1

    move v2, v0

    goto :goto_8

    .line 365
    :cond_19
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->size()I

    move-result v2

    .line 367
    :goto_1f
    if-ge v1, v2, :cond_da

    .line 369
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    .line 370
    iget-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileX:Z

    if-eqz v3, :cond_37

    .line 371
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getX()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceX:F

    add-float/2addr v3, v4

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setX(F)V

    .line 375
    :cond_37
    iget-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileY:Z

    if-eqz v3, :cond_45

    .line 376
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getY()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceY:F

    add-float/2addr v3, v4

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setY(F)V

    .line 381
    :cond_45
    iget-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileZ:Z

    if-eqz v3, :cond_53

    .line 382
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getZ()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceZ:F

    add-float/2addr v3, v4

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setZ(F)V

    .line 388
    :cond_53
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getVelocityX()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_friction:F

    div-float/2addr v3, v4

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setVelocityX(F)V

    .line 389
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getVelocityY()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_friction:F

    div-float/2addr v3, v4

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setVelocityY(F)V

    .line 390
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getVelocityZ()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_friction:F

    div-float/2addr v3, v4

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setVelocityZ(F)V

    .line 392
    iget-boolean v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_useBounds:Z

    if-eqz v3, :cond_a2

    .line 393
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getX()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinX:F

    cmpg-float v3, v3, v4

    if-gez v3, :cond_aa

    .line 394
    iget v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinX:F

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setX(F)V

    .line 397
    :cond_84
    :goto_84
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getY()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinY:F

    cmpg-float v3, v3, v4

    if-gez v3, :cond_ba

    .line 398
    iget v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinY:F

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setY(F)V

    .line 402
    :cond_93
    :goto_93
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getZ()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinZ:F

    cmpg-float v3, v3, v4

    if-gez v3, :cond_ca

    .line 403
    iget v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinZ:F

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setZ(F)V

    .line 408
    :cond_a2
    :goto_a2
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->update()V

    .line 367
    add-int/lit8 v0, v1, 0x1

    move v1, v0

    goto/16 :goto_1f

    .line 395
    :cond_aa
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getX()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxX:F

    cmpl-float v3, v3, v4

    if-lez v3, :cond_84

    .line 396
    iget v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxX:F

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setX(F)V

    goto :goto_84

    .line 399
    :cond_ba
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getY()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxY:F

    cmpl-float v3, v3, v4

    if-lez v3, :cond_93

    .line 400
    iget v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxY:F

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setY(F)V

    goto :goto_93

    .line 404
    :cond_ca
    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->getZ()F

    move-result v3

    iget v4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxZ:F

    cmpl-float v3, v3, v4

    if-lez v3, :cond_a2

    .line 405
    iget v3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxZ:F

    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->setZ(F)V

    goto :goto_a2

    .line 412
    :cond_da
    return-void
.end method

.method public clearBounds()V
    .registers 2

    .prologue
    .line 77
    const/4 v0, 0x0

    iput-boolean v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_useBounds:Z

    .line 78
    return-void
.end method

.method public getForceX()F
    .registers 2

    .prologue
    .line 135
    iget v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceX:F

    return v0
.end method

.method public getForceY()F
    .registers 2

    .prologue
    .line 147
    iget v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceY:F

    return v0
.end method

.method public getForceZ()F
    .registers 2

    .prologue
    .line 159
    iget v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceZ:F

    return v0
.end method

.method public getFriction()F
    .registers 3

    .prologue
    .line 89
    iget v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_friction:F

    const/high16 v1, 0x3f800000    # 1.0f

    sub-float/2addr v0, v1

    const/high16 v1, 0x42c80000    # 100.0f

    mul-float/2addr v0, v1

    return v0
.end method

.method public getRigidity()F
    .registers 2

    .prologue
    .line 104
    iget v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_rigidity:F

    return v0
.end method

.method public getVerletVertices()Ljava/util/ArrayList;
    .registers 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()",
            "Ljava/util/ArrayList",
            "<",
            "Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;",
            ">;"
        }
    .end annotation

    .prologue
    .line 81
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    return-object v0
.end method

.method public lockXMax()V
    .registers 5

    .prologue
    .line 224
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMaxX()F

    move-result v0

    const-string/jumbo v1, "x"

    const/4 v2, 0x0

    const/4 v3, 0x7

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 225
    return-void
.end method

.method public lockXMax(FI)V
    .registers 5

    .prologue
    .line 220
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMaxX()F

    move-result v0

    const-string/jumbo v1, "x"

    invoke-direct {p0, v0, v1, p1, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 221
    return-void
.end method

.method public lockXMin()V
    .registers 5

    .prologue
    .line 202
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMinX()F

    move-result v0

    .line 203
    const-string/jumbo v1, "x"

    const/4 v2, 0x0

    const/4 v3, 0x7

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 204
    return-void
.end method

.method public lockXMin(FI)V
    .registers 5

    .prologue
    .line 198
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMinX()F

    move-result v0

    const-string/jumbo v1, "x"

    invoke-direct {p0, v0, v1, p1, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 199
    return-void
.end method

.method public lockYMax()V
    .registers 5

    .prologue
    .line 267
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMaxY()F

    move-result v0

    const-string/jumbo v1, "y"

    const/4 v2, 0x0

    const/4 v3, 0x7

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 268
    return-void
.end method

.method public lockYMax(FI)V
    .registers 5

    .prologue
    .line 263
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMaxY()F

    move-result v0

    const-string/jumbo v1, "y"

    invoke-direct {p0, v0, v1, p1, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 264
    return-void
.end method

.method public lockYMin()V
    .registers 5

    .prologue
    .line 246
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMinY()F

    move-result v0

    const-string/jumbo v1, "y"

    const/4 v2, 0x0

    const/4 v3, 0x7

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 247
    return-void
.end method

.method public lockYMin(FI)V
    .registers 5

    .prologue
    .line 242
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMinY()F

    move-result v0

    const-string/jumbo v1, "y"

    invoke-direct {p0, v0, v1, p1, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 243
    return-void
.end method

.method public lockZMax()V
    .registers 5

    .prologue
    .line 308
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMaxZ()F

    move-result v0

    const-string/jumbo v1, "z"

    const/4 v2, 0x0

    const/4 v3, 0x7

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 309
    return-void
.end method

.method public lockZMax(FI)V
    .registers 5

    .prologue
    .line 304
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMaxZ()F

    move-result v0

    const-string/jumbo v1, "z"

    invoke-direct {p0, v0, v1, p1, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 305
    return-void
.end method

.method public lockZMin()V
    .registers 5

    .prologue
    .line 287
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMinZ()F

    move-result v0

    const-string/jumbo v1, "z"

    const/4 v2, 0x0

    const/4 v3, 0x7

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 288
    return-void
.end method

.method public lockZMin(FI)V
    .registers 5

    .prologue
    .line 283
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->mod:Lcom/censivn/C3DEngine/effects/core/MeshProxy;

    invoke-virtual {v0}, Lcom/censivn/C3DEngine/effects/core/MeshProxy;->getMinZ()F

    move-result v0

    const-string/jumbo v1, "z"

    invoke-direct {p0, v0, v1, p1, p2}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->lockSet(FLjava/lang/String;FI)V

    .line 284
    return-void
.end method

.method public setBounds()V
    .registers 4

    .prologue
    const/high16 v2, -0x800000    # Float.NEGATIVE_INFINITY

    .line 60
    .line 61
    const/high16 v0, 0x7f800000    # Float.POSITIVE_INFINITY

    .line 67
    const/4 v1, 0x1

    iput-boolean v1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_useBounds:Z

    .line 68
    iput v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinX:F

    .line 69
    iput v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxX:F

    .line 70
    iput v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinY:F

    .line 71
    iput v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxY:F

    .line 72
    iput v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinZ:F

    .line 73
    iput v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxZ:F

    .line 74
    return-void
.end method

.method public setBounds(FFFFFF)V
    .registers 8

    .prologue
    .line 49
    const/4 v0, 0x1

    iput-boolean v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_useBounds:Z

    .line 50
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinX:F

    .line 51
    iput p2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxX:F

    .line 52
    iput p3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinY:F

    .line 53
    iput p4, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxY:F

    .line 54
    iput p5, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMinZ:F

    .line 55
    iput p6, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_boundsMaxZ:F

    .line 56
    return-void
.end method

.method public setForce(FFF)V
    .registers 4

    .prologue
    .line 129
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceX:F

    .line 130
    iput p2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceY:F

    .line 131
    iput p3, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceZ:F

    .line 132
    return-void
.end method

.method public setForceX(F)V
    .registers 2

    .prologue
    .line 139
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceX:F

    .line 140
    return-void
.end method

.method public setForceY(F)V
    .registers 2

    .prologue
    .line 151
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceY:F

    .line 152
    return-void
.end method

.method public setForceZ(F)V
    .registers 2

    .prologue
    .line 163
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_forceZ:F

    .line 164
    return-void
.end method

.method public setFriction(F)V
    .registers 4

    .prologue
    const/4 v0, 0x0

    .line 93
    cmpg-float v1, p1, v0

    if-gez v1, :cond_6

    move p1, v0

    .line 96
    :cond_6
    const/high16 v0, 0x42c80000    # 100.0f

    div-float v0, p1, v0

    const/high16 v1, 0x3f800000    # 1.0f

    add-float/2addr v0, v1

    iput v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_friction:F

    .line 97
    return-void
.end method

.method public setModifiable(Lcom/censivn/C3DEngine/effects/core/MeshProxy;)V
    .registers 3

    .prologue
    .line 342
    invoke-super {p0, p1}, Lcom/censivn/C3DEngine/effects/core/Modifier;->setModifiable(Lcom/censivn/C3DEngine/effects/core/MeshProxy;)V

    .line 344
    invoke-direct {p0}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->initVerletVertices()V

    .line 345
    invoke-direct {p0}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->initVerletConnections()V

    .line 346
    iget v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_rigidity:F

    invoke-virtual {p0, v0}, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->setRigidity(F)V

    .line 347
    return-void
.end method

.method public setRigidity(F)V
    .registers 6

    .prologue
    const/high16 v0, 0x3f800000    # 1.0f

    const/4 v1, 0x0

    .line 109
    iget-object v2, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_connections:Ljava/util/ArrayList;

    invoke-virtual {v2}, Ljava/util/ArrayList;->size()I

    move-result v2

    .line 112
    cmpl-float v3, p1, v0

    if-lez v3, :cond_27

    move p1, v0

    .line 117
    :cond_e
    :goto_e
    iput p1, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_rigidity:F

    .line 118
    const/high16 v0, 0x3f000000    # 0.5f

    mul-float v3, p1, v0

    .line 120
    const/4 v0, 0x0

    move v1, v0

    :goto_16
    if-ge v1, v2, :cond_2d

    .line 122
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_connections:Ljava/util/ArrayList;

    invoke-virtual {v0, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;

    .line 123
    invoke-virtual {v0, v3}, Lcom/censivn/C3DEngine/effects/core/verlet/VerletConnection;->setRigidity(F)V

    .line 120
    add-int/lit8 v0, v1, 0x1

    move v1, v0

    goto :goto_16

    .line 114
    :cond_27
    cmpg-float v0, p1, v1

    if-gez v0, :cond_e

    move p1, v1

    .line 115
    goto :goto_e

    .line 126
    :cond_2d
    return-void
.end method

.method public unlockAll()V
    .registers 5

    .prologue
    const/4 v3, 0x1

    .line 172
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->size()I

    move-result v2

    .line 174
    const/4 v0, 0x0

    move v1, v0

    :goto_9
    if-ge v1, v2, :cond_1d

    .line 176
    iget-object v0, p0, Lcom/censivn/C3DEngine/effects/modifiers/Cloth;->_vertices:Ljava/util/ArrayList;

    invoke-virtual {v0, v1}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;

    .line 177
    iput-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileX:Z

    .line 178
    iput-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileY:Z

    .line 179
    iput-boolean v3, v0, Lcom/censivn/C3DEngine/effects/core/verlet/VerletVertex;->mobileZ:Z

    .line 174
    add-int/lit8 v0, v1, 0x1

    move v1, v0

    goto :goto_9

    .line 182
    :cond_1d
    return-void
.end method