DAdjustableModelPanel Bug?

I’m playing with the DAdjustableModelPanel and found a pretty irritating problem.
I do not know if it’s a bug or not but I would really like to know if there is a solution.

When creating a DAdjustableModelPanel everything works fine with no errors but it’s invisible!
To be able to see and use (drag around and inspect the model) one must first click in the invisible box where it should be before the model pops up.
It’s like it isn’t setting the model or refreshing it until the user clicks inside of it to activate the dragging mechanic.



	local mp = vgui.Create( "DAdjustableModelPanel", modelPanel )
	mp:SetPos( 0, 0 )
	mp:SetSize( w-w/3, h )
	mp:SetLookAt( Vector( 0, 0, 0 ) )
	mp:SetModel( CurrentModel )


Thank’s everyone for reading!

You must set the initial camera position and angles yourself, I don’t understand what makes you think it should do that for you automatically.

Okay guys. I literally just solved the problem.
For some reason the CamPos was really strange and was looking away from the model.
To get a CamPos that looks exactly like the DAdjustableModelPanel’s when dragging, set it to:

___:SetCamPos( Vector( -100, 0, 0 ) )

This will fix it and make it look like a smooth transition between a static one and one being dragged.

Thanks anyway. Sorry for wasting anyone’s time by posting this in the first place.
Hopefully it helps someone else one day…

[editline]15th April 2016[/editline]

I just figured that out but thanks anyway and the reason I thought it will work fine is because the example on

doesn’t state anything about CamPos.

Thanks!