1. -- 
  2. -- Copyright (c) 2012 Kevin Wellwood 
  3. -- All rights reserved. 
  4. -- 
  5. -- This source code is distributed under the Modified BSD License. For terms and 
  6. -- conditions, see license.txt. 
  7. -- 
  8.  
  9. with Values;                            use Values; 
  10.  
  11. package Game_States is 
  12.  
  13.     -- Presents a view of the current game session's state. The Game class 
  14.     -- implements this so that game components can access the session's state 
  15.     -- without having a full reference to the Game class. 
  16.     type Game_State is limited interface; 
  17.     type A_Game_State is access all Game_State'Class; 
  18.  
  19.     -- Returns the value of session var 'name', or Null_Value if not defined. 
  20.     function Get_Var( this : access Game_State; 
  21.                       name : String ) return Value_Ptr is abstract; 
  22.  
  23.     -- Sets session var 'name' to 'value'. A Game_Var_Changed event will be 
  24.     -- queued. 
  25.     procedure Set_Var( this  : access Game_State; 
  26.                        name  : String; 
  27.                        value : Value_Ptr'Class ) is abstract; 
  28.  
  29. end Game_States;