Skip to content

[BUG] _this missing from arguments when transpiling a function #165

@overfl0

Description

@overfl0
player addEventHandler ["HandleDamage", {
    hint format ["You just sustained %1%2 damage!", ceil ((_this select 2) * 100), "%"];
}];

Gives:

player.addeventhandler("HandleDamage", function() {
    hint($"You just sustained {ceil(_this[2] * 100)}{"%"} damage!");
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugError, flaw, failure or fault that causes to produce an incorrect result or crashsqc

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions