-
Notifications
You must be signed in to change notification settings - Fork 18
Widget3D_Methods_visibility
ben-mkiv edited this page Jun 27, 2020
·
2 revisions
The Looking At Lets you render an object only if you are looking at a specified block.
Objects with this Attribute have the following functions available:
getLookingAt():number,number,number,boolean
-- Returns the coordinates of the set block and if the function is currently on or off.
setLookingAt(isLookingAt:boolean)
-- Lets you disable or enable this functionality.
setLookingAt(x:number,y:number,z:number)
-- Lets you set the block, which triggers the rendering of the object.
-- The x, y and z are integer values indicating absolute coordinates of the block in the world.control the distance from which a widget can be seen
getViewDistance():number
-- returns the current view distance
setViewDistance(number:distance)
-- sets the distance from which the widget can be seenvisibility
isVisible():boolean
-- returns true if the widget will be rendered
setVisible(boolean:visibility)
-- controls visibility of the widgetvisibility through other objects
note: rendering through objects can give unexpected results when rendering widgets with transparency. As minecraft doesn't depth sort the widgets a widget which is further away can overlay a widget which is closer to the player
isVisibleThroughObjects():boolean
-- returns true if the widget will be rendered when obstructed by blocks
setVisibleThroughObjects(boolean:visibility)
-- controls if the widget will be visible behind blocks