create new constructor for VmcExtKey
This commit is contained in:
parent
023db85b1b
commit
30a960ef0b
|
@ -52,5 +52,17 @@ namespace godotVmcSharp
|
|||
name = (string)m.Data[1].Value;
|
||||
keycode = (int)m.Data[2].Value;
|
||||
}
|
||||
|
||||
public VmcExtKey(int _active, string _name, int _keycode) : base(new godotOscSharp.Address("/VMC/Ext/Key"))
|
||||
{
|
||||
if (_active < 0 || _active > 1)
|
||||
{
|
||||
GD.Print($"Invalid value for \"active\" 'i' argument of {addr}. Expected 0 or 1, received {_active}");
|
||||
return;
|
||||
}
|
||||
active = _active;
|
||||
name = _name;
|
||||
keycode = _keycode;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user