Skip to content
Thomas edited this page Aug 2, 2020 · 2 revisions

obj_uiZ_cover

An object made to cover things up when menus or popups are open. This object may at any point destroy itself when destroyonclick is set to true, please check whether it still exists when using it.

The cover is just a square being drawn consisting of a color and alpha. To set the alpha, use the built in alpha function of uiz: uiz_alpha(instanceid, head_alpha, image_alpha).

For an example on how to use this, take a look at obj_uiZ_template_0

Property Variables

  • color[c_black]: The color the cover should have.
  • enabled[true]: Whether the cover is enabled or not. If it isn't enabled then the mouse will be completely ignored (pass through the object) and nothing will be drawn.
  • disablemouse[true]: Whether the object should allow mouse clicks to pass or not. True for not letting clicks pass(actually normal uiz object behavior) behind the cover, and false for letting mouse clicks pass.
  • ignorecontain[false]: Whether to disable any containment by uiz. Enabling this allows this objects to be drawn outside the bounds of it's parent.
  • destroyonclick[true]: Whether to destroy the object when you click it. (With an animation though)
  • destroyalphaanimation[uiz_cubic_inout]: The animation to use when the object gets destroyed.
  • destroyalphaanimationtime[uiz_cubic_inout]: The time in seconds the destroyalphaanimation takes.

Readable variables

  • update: Whenever this object is being pressed. (kmouseover=2)
  • updated: Whenever this object is in its destroy animation.

Functions

  • uiz_cover_setcolor(instanceid, color):
    • instanceid: the instance id of the instance you want to modify
    • color[c_black]: The color the cover shou
  • uiz_cover_settings(instanceid, disablemouse, ignorecontain,destroyonclick):
    • instanceid: the instance id of the instance you want to modify
    • disablemouse[true]: Whether the object should allow mouse clicks to pass or not. True for not letting clicks pass(actually normal uiz object behavior) behind the cover, and false for letting mouse clicks pass.
    • ignorecontain[false]: Whether to disable any containment by uiz. Enabling this allows this objects to be drawn outside the bounds of it's parent.
    • destroyonclick[true]: Whether to destroy the object when you click it. (With an animation though)
  • uiz_cover_setanimation(instanceid, destroyalphaanimation, destroyalphaanimationtime):
    • instanceid: the instance id of the instance you want to modify
    • destroyalphaanimation[uiz_cubic_inout]: The animation to use when the object gets destroyed.
    • destroyalphaanimationtime[uiz_cubic_inout]: The time in seconds the destroyalphaanimation takes.

Wiki pages

🏑Home / General
πŸ“ƒTutorials
πŸ‘ͺ Parent
↕️ Positioning
πŸ›  Fixing & Updating
πŸ• Depth
πŸ“ƒ Templates and Examples
πŸŒ† Background
πŸ“‡ Structures
🎈 Objects

obj_uiZ_3waybutton
obj_uiZ_button
obj_uiZ_checkbox
obj_uiZ_clock
obj_uiZ_colorbox
obj_uiZ_cover
obj_uiZ_drawdslist obj_uiZ_dropdown
obj_uiZ_easybutton
obj_uiZ_frame
obj_uiZ_framescrollbar
obj_uiZ_functionbar
obj_uiZ_gradientsquare
obj_uiZ_gradientroundrect
obj_uiZ_gridlist
obj_uiZ_huesquare
obj_uiZ_loadingbar
obj_uiZ_loadingcircle
obj_uiZ_menubutton
obj_uiZ_mousemenu
obj_uiZ_radiobox
obj_uiZ_rotator
obj_uiZ_slider
obj_uiZ_scrollbar
obj_uiZ_slider_2col
obj_uiZ_slickslider
obj_uiZ_slideframe
obj_uiZ_sprbutton
obj_uiZ_spriteanimationbutton
obj_uiZ_spritecounter
obj_uiZ_stringbox
obj_uiZ_sliderstruct
obj_uiZ_surfacecanvas
obj_uiZ_sprite
obj_uiZ_square
obj_uiZ_squarebutton
obj_uiZ_swipicon
obj_uiZ_switch
obj_uiZ_tabslider
obj_uiZ_tabs
obj_uiZ_treelist
obj_uiZ_text
obj_uiZ_text_background
obj_uiZ_textarea
obj_uiZ_valuebox


🎈 Your own objects
🚫 Destroy
🐭 Mouse
πŸ’» Windows (uiz)
🌌 Animations
❓ General
πŸ“’ Numbers
πŸ“’ Strings
✏️ Draw
🚩 Popup
πŸ“‚ Files
πŸ’» Windows (os)
Clone this wiki locally