constrain-distance

<script src="./point_src/constrain-distance"></script>

Meta Data
filepath_exists True
path constrain-distance
filepath constrain-distance.js
clean_files ()

  • VariableDeclaration
    const

    constraints

    =
    ObjectExpression
    Same as: const ratio = maxDistance / distance; pointB.x = pointA.x - d2d.x * ratio; pointB.y = pointA.y - d2d.y * ratio;
  • VariableDeclaration
    const

    stringAttach

    =
    function ( followPoint , originPoint , settings )
    Apply gravity to the follow point's vertical velocity
  • ClassDeclaration
    class comments:
    string stuff
    • constructor

      constructor

      (
      point
      )
      from class_name
      dict_keys(['kind', 'word', 'static', 'computed', 'is_symbol', 'value', 'type', 'comments', 'pos'])
      string stuff
    • method

      track

      (
      other , settings
      )
      from class_name
      dict_keys(['kind', 'word', 'static', 'computed', 'is_symbol', 'value', 'type', 'comments', 'pos'])
      Track another point using IK - this point follows the _other_ at a set distance.
      return followPoint(other, this, settings)
    • method

      leash

      (
      other , settings
      )
      from class_name
      dict_keys(['kind', 'word', 'static', 'computed', 'is_symbol', 'value', 'type', 'comments', 'pos'])
      Track another point using constraints. This point follows the other point at a distance or less.
    • method

      avoid

      (
      other , settings
      )
      from class_name
      dict_keys(['kind', 'word', 'static', 'computed', 'is_symbol', 'value', 'type', 'comments', 'pos'])
      Ensure this point does not overlap the _other_ point. If an overlap occurs, this point is moved. Fundamentally this is the antethsis of leash().
    • method

      elbow

      (
      other , settings
      )
      from class_name
      dict_keys(['kind', 'word', 'static', 'computed', 'is_symbol', 'value', 'type', 'comments', 'pos'])
      Connect this point and another point by their _edges_. Similar to _track_ at a distance, but accounting for radius.
    • method

      string

      (
      other , settings
      )
      from class_name
      dict_keys(['kind', 'word', 'static', 'computed', 'is_symbol', 'value', 'type', 'comments', 'pos'])
      Manipulate the _other_; with this entity as the origin owner.
    dict_keys(['kind', 'word', 'parentName', 'type', 'body', 'comments', 'pos'])
  • ExpressionStatement

    :

    dict_keys(['type', 'expression', 'pos'])
  • ExpressionStatement

    :

    dict_keys(['type', 'expression', 'pos'])