GetWorldElementVisible
State = GetWorldElementVisible(WorldIndex)
 
Parameters:

    WorldIndex = The Index of the world you wish to query
Returns:

    State = The state flag of this element (0=hidden, 1 = Visible)
 

      The GetWorldElementVisible funtions returns the current visibility status of a captured element within a world.



FACTS:


      * Hidden elements are neither drawn or checked during collision or ray intersection operations with the world



Mini Tutorial:


      This example simply creates a world, captures some of lines to it, then displays the visibility status of these elements.


  
; create a world and capture some lines to it
  id=NewWorld()
  CaptureToWorld Id
  
  For lp=0 To 10
     Line 100,100+(lp*5),200,200+(lp*10)
  Next
  
; Hide element 5 in this world
  WorldElementVisible id,5,off
  
;Restore drawing to normal
  DrawGFXImmediate
  
  Print GetWorldElements(id)
  
; display the Visible status of the element
; in this world
  For lp=0 To GetWorldElements(id)
     Print GetWorldElementVisible(id,lp)
  Next
  
; Display the screen and wait for a key press
  Sync
  WaitKey
  



This example would output.

  
  11
  1
  1
  1
  1
  0
  1
  1
  1
  1
  1
  0
  

 
Related Info: GetWorldElements | GetWorldStatus | WorldElementVisible :
 


(c) Copyright 2002 - 2024 - Kevin Picone - PlayBASIC.com