public Vector2f normalizeLocal() {
        float length = length();
        if (length != 0) {
            return divideLocal(length);
        }

        return divideLocal(1);
    }
Normalizes the vector to length=1 and returns the (modified) current
instance. If the vector has length=0, it's unchanged.

@return the (modified) current instance (for chaining)
jme3-core/src/main/java/com/jme3/math/Vector2f.java