Class SKFieldNode

    • Constructor Detail

      • SKFieldNode

        protected SKFieldNode​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • allocWithZone

        public static java.lang.Object allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(java.lang.Object aTarget,
                                                                                 org.moe.natj.objc.SEL aSelector,
                                                                                 java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        public static org.moe.natj.objc.Class classForKeyedUnarchiver()
      • clearTextInputContextIdentifier

        public static void clearTextInputContextIdentifier​(java.lang.String identifier)
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • dragField

        public static SKFieldNode dragField()
        Slows an object proportionally to the object’s velocity. Use this to simulate effects such as friction from motion through the air.
      • electricField

        public static SKFieldNode electricField()
        A force proportional to the charge on the object. A charge property has been added to SKPhysicsBodies to accomplish this. An example use of this field is to make objects behavior differently from one another when they enter a region, or to make an object's behavior different than its mass based behavior This field models the first part of the Lorentz equation, F = qE
      • hash_static

        public static long hash_static()
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • keyPathsForValuesAffectingValueForKey

        public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(java.lang.String key)
      • magneticField

        public static SKFieldNode magneticField()
        A force proportional to the charge on the object and the object’s velocity. A charge property has been added to SKPhysicsBodies to accomplish this. An example use of this field is to make objects behavior differently from one another when they enter a region, or to make an object's behavior different than its mass based behavior This field models the second part of the Lorentz equation, F = qvB
      • new_objc

        public static java.lang.Object new_objc()
      • nodeWithFileNamed

        public static SKFieldNode nodeWithFileNamed​(java.lang.String filename)
      • noiseFieldWithSmoothnessAnimationSpeed

        public static SKFieldNode noiseFieldWithSmoothnessAnimationSpeed​(double smoothness,
                                                                         double speed)
        A time varying differentiable Perlin simplex noise field. By default a smooth noise is calculated, and the field is time varying. Use this to simulate such effects as fireflies, or snow. To freeze the noise in place, set animationSpeed to 0.0. Mass is ignored.
        Parameters:
        smoothness - value of 0 means as noisy as possible, 1 means as smooth as possible
        speed - is the general rate in Hz that any particular texel changes to a different value
        See Also:
        smoothness(), animationSpeed()
      • radialGravityField

        public static SKFieldNode radialGravityField()
        Applies a force in the direction of the origin of the field in local space. To repel objects, use a negative strength. The force is proportional to the distance from the field origin. Varies with the mass of the object according to F = ma The field node's rotation property can be used to orient the gravity in a particular direction.
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • springField

        public static SKFieldNode springField()
        A Hooke’s law force - a force linearly proportional to distance from the center of the field. An object in this field will oscillate with a period proportional to the inverse of the mass. An example use is to keep objects confined to a particular region.
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • turbulenceFieldWithSmoothnessAnimationSpeed

        public static SKFieldNode turbulenceFieldWithSmoothnessAnimationSpeed​(double smoothness,
                                                                              double speed)
        Just like Noise, except the strength of the noise is proportional to the velocity of the object in the field.
        Parameters:
        smoothness - value of 0 means as noisy as possible, 1 means as smooth as possible
        speed - is the general rate in Hz that any particular texel changes to a different value
        See Also:
        smoothness(), animationSpeed()
      • velocityFieldWithTexture

        public static SKFieldNode velocityFieldWithTexture​(SKTexture velocityTexture)
        The supplied texture contains velocity values for any object entering the field’s area of effect. If no texture is supplied, the direction property is used instead. Velocity fields override the effect of any other acceleration applied to the body. Velocity fields are typically used for such effects as advection, for example, a velocity field might describe the velocity on the surface of a river. An object placed in the river would then follow the river.
        Parameters:
        velocityTexture - The R and G channels of the supplied texture become x and y components of velocity. B and A, if present in the SKTexture, are ignored.
        See Also:
        texture()
      • version_static

        public static long version_static()
      • vortexField

        public static SKFieldNode vortexField()
        Applies a force tangential to the direction from the sample point to the field's position. The force will be CCW to the direction. Make the strength negative to apply force in the CW direction. Amount is proportional to distance from center and the object's mass. Use this to create effects such as tornadoes.
      • animationSpeed

        public float animationSpeed()
        fields that can be animated can have non zero values. A value of 2 will animated twice as fast as a value of 1.
      • categoryBitMask

        public int categoryBitMask()
        Logical categories the field belongs to. Default is all categories. These categories correspond to fieldBitMasks, and can be used to enforce that a particular field applies to a particular category of objects.
        See Also:
        SKPhysicsBody.fieldBitMask, SKEmitterNode.fieldBitMask
      • falloff

        public float falloff()
        The falloff exponent used to calculate field strength at a distance. Falloff starts at the minimum radius. The default exponent is zero, which results in a uniform field with no falloff.
        See Also:
        minimumRadius()
      • isEnabled

        public boolean isEnabled()
        If enabled, a field has an effect. default YES
      • setEnabled

        public void setEnabled​(boolean value)
        If enabled, a field has an effect. default YES
      • isExclusive

        public boolean isExclusive()
        If a field is exclusive, it suppresses any other field in its region of effect. If two or more exclusive fields overlap, it is undefined which one of them will take effect
        See Also:
        region()
      • setExclusive

        public void setExclusive​(boolean value)
        If a field is exclusive, it suppresses any other field in its region of effect. If two or more exclusive fields overlap, it is undefined which one of them will take effect
        See Also:
        region()
      • minimumRadius

        public float minimumRadius()
        minimum radius of effect. Default is very small.
      • region

        public SKRegion region()
        The region property is the domain of the field's effect. No force is applied to objects outside the region.
      • setAnimationSpeed

        public void setAnimationSpeed​(float value)
        fields that can be animated can have non zero values. A value of 2 will animated twice as fast as a value of 1.
      • setCategoryBitMask

        public void setCategoryBitMask​(int value)
        Logical categories the field belongs to. Default is all categories. These categories correspond to fieldBitMasks, and can be used to enforce that a particular field applies to a particular category of objects.
        See Also:
        SKPhysicsBody.fieldBitMask, SKEmitterNode.fieldBitMask
      • setFalloff

        public void setFalloff​(float value)
        The falloff exponent used to calculate field strength at a distance. Falloff starts at the minimum radius. The default exponent is zero, which results in a uniform field with no falloff.
        See Also:
        minimumRadius()
      • setMinimumRadius

        public void setMinimumRadius​(float value)
        minimum radius of effect. Default is very small.
      • setRegion

        public void setRegion​(SKRegion value)
        The region property is the domain of the field's effect. No force is applied to objects outside the region.
      • setSmoothness

        public void setSmoothness​(float value)
        fields without a smoothness component will return 0
      • setStrength

        public void setStrength​(float value)
        strength scaling value. default 1.0
      • setTexture

        public void setTexture​(SKTexture value)
        fields constructed with a texture can be uppdated by assigning a new texture
      • smoothness

        public float smoothness()
        fields without a smoothness component will return 0
      • strength

        public float strength()
        strength scaling value. default 1.0
      • texture

        public SKTexture texture()
        fields constructed with a texture can be uppdated by assigning a new texture
      • nodeWithFileNamedSecurelyWithClassesAndError

        public static SKFieldNode nodeWithFileNamedSecurelyWithClassesAndError​(java.lang.String filename,
                                                                               NSSet<? extends org.moe.natj.objc.Class> classes,
                                                                               org.moe.natj.general.ptr.Ptr<NSError> error)
      • supportsSecureCoding

        public static boolean supportsSecureCoding()
      • _supportsSecureCoding

        public boolean _supportsSecureCoding()
        Description copied from interface: NSSecureCoding
        This property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.
        Specified by:
        _supportsSecureCoding in interface NSSecureCoding
        Overrides:
        _supportsSecureCoding in class SKNode