Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improper Type Conversion for Overloads #186

Open
Falkitop opened this issue Apr 5, 2024 · 0 comments
Open

Improper Type Conversion for Overloads #186

Falkitop opened this issue Apr 5, 2024 · 0 comments

Comments

@Falkitop
Copy link

Falkitop commented Apr 5, 2024

NeoLua Version:

Example to reproduce:

function AddAngularForce()
    local r = floatQ.Euler(float3(0, 0.01, 0))
    AngularVelocity= floatQ.Multiply(AngularVelocity, r)
    --Works!
end

function AddAngularForce()
    AngularVelocity= floatQ.Multiply(AngularVelocity, floatQ.Euler(float3(0, 0.01, 0)))
    --Doesnt work!
end

The declarations for context:

    public static floatQ Multiply(ref floatQ q, float n)
    
    public static floatQ Multiply(ref floatQ a, ref floatQ b)
    
    public static floatQ Euler(in float3 rotation)
    

The resulting error is: Neo.lronLua.LuaRuntimeException: No conversion defined from floatQ to Single.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant