Describe the bug
When updating the Auto Translate modifier, it needs 3 arguments despite it only using 2. I think it's just a copy and paste leftover here :
|
@Callback(doc = "function(Double:x, Double:y, Double:z):boolean -- sets new values", direct = true) |
|
public Object[] set(Context context, Arguments args){ |
|
if(!args.isDouble(0) || !args.isDouble(1) || !args.isDouble(2)) |
|
return new Object[]{ false, "3 values(Double) required! x,y,z" }; |
In which environment did the Bug appear?
Singleplayer, Forge server
To Reproduce
Steps to reproduce the behavior:
- In the lua interpreter, type in the code snippet below
Expected behavior
It should update the modifier with 2 arguments.
Screenshots / Code Snippet
g = component.glasses
g.removeAll()
t = g.addText2D()
t.addAutoTranslation(10,10)
t.updateModifier(1,20,20) -- This works
m = t.modifiers()[1]
m.set(20,20) -- This should work but doesn't
m.set(20,20,0) -- This does work
Minecraft:
- Mod Version: OpenGlasses-MC1.12.2-2.2-53
- Minecraft Version: 1.12.2
- Forge Version: 14.23.5.2854
Additional context
- OpenComputers Version: 1.7.5.192
Describe the bug
When updating the Auto Translate modifier, it needs 3 arguments despite it only using 2. I think it's just a copy and paste leftover here :
OCGlasses/src/main/java/com/bymarcin/openglasses/lua/luafunction/modifiers/ModifierAutoTranslate.java
Lines 26 to 29 in e6c5093
In which environment did the Bug appear?
Singleplayer, Forge server
To Reproduce
Steps to reproduce the behavior:
Expected behavior
It should update the modifier with 2 arguments.
Screenshots / Code Snippet
Minecraft:
Additional context