Open JordanStoute opened 8 months ago
I have not tried it in 4.2 yet. I will make some time and track down the issue soon. Thanks for reporting!
Anecdotally it is working fine for me in 4.2, but I had an existing 4.1 project that I updated. I haven't tried pulling it into a fresh 4.2 project yet.
Tried porting into Godot 4
But neither 4.1.3 nor 4.2 worked with the automatic conversion.
Tried adding a Material with the shader for the MeshInstance3D inside MirrorContainer scene and it shows a clear blue colored texture in editor but in-game it just renders pink without that change it just spits:
res://addons/Mirror/Mirror/Mirror.gd:49 - Attempt to call function 'set_shader_parameter' in base 'null instance' on a null instance.
Editor:
In-game:
If you add a mesh to the MirrorContianer.tscn
it kinda works:
@IsukyPohlo Are you trying auto conversion on the main branch? I think you should try the godot4 branch. As far as I can remember that works on some 4.1 godot version. I will take a closer look later
@Norodix
Sorry I mixed up my projects and thought godot4
was not working.
The branch is currently working with Godot 4.2 stable 👍
@JordanStoute, Sorry for the late reply. I looked into it and it seems to work for me just as well in 4.2 as in 4.1. Please make sure you are using the godot4 branch. If it still doesn't work, can you send me a minimal reproducible example?
@Norodix
I happend to have the same error like op, only when I restarted Godot 4.2.1, after installing the plugin.
It had to do with wrong pathing (the path used on preload
in plugin.gd. Somehow the "Mirror" folder is redundant. Also the Mirror.gd had wrong pathing. I fixed it for me, I guess.
But it also doesn't work for me, the mirror just stays black.
After I changed the size properties of the Mirror Node, I got these fragments on the Mirror
oh okay now it is working the mirrors mesh was not in my camera cull layers
If I use it as a child of type "Mirror" it will create two scenes in the remote tree also and one is overlaying the other so the mirror is not visible. It only works if I attach the "Mirror.gd" file to a Node3D directly
I don't think I follow you. Can you provide an example or some screenshots?
Hm so basically it only works when I attach the Mirror.gd to a Node3D like in the Demo..
You are not supposed to attach mirror.gd to anything. You should add new mirror nodes. They are a class, so they appear in the "Create new node" menu.
Yeah that is not working. So I worked around it and made it like in the demo... works now very well (It was also jumping twice into _enter_tree
and I fixed that, it caused flickering)
Description If I try to enable the plugin, it says "Unable to load addon script from path: 'res://addons/Mirror/plugin.gd'. This might be due to a code error in that script. Disabling the addon at 'res://addons/Mirror/plugin.cfg' to prevent further errors.
Screenshots![mirror plugin wont work](https://github.com/Norodix/GodotMirror/assets/81189905/47acd2db-bf0c-4c19-af50-a911dce60127)
Godot version v4.2.stable.official [46dc27791]
Platform Windows 10