04-18-2021, 01:43 PM
Code:
Object ep = ReflectionUtil.invokeMethod(p.getClass(), p, "getHandle");
Object profile = ReflectionUtil.invokeMethod(ep.getClass(), ep, "getProfile");
Object propMap = ReflectionUtil.invokeMethod(profile.getClass(), profile, "getProperties");
ReflectionUtil.invokeMethod(propMap, "clear");
ReflectionUtil.invokeMethod(propMap.getClass(), propMap, "put", new Class[]{Object.class, Object.class}, "textures", props);
It seems like that this is some acres to the mojang code of spigot.