home *** CD-ROM | disk | FTP | other *** search
/ UnrealScript Game Programming All in One / UnrealScriptGameProgrammingAllInOne.iso / UGPAIOListings / UGPAIOListingsCh20 / CH20LIST / Classes / CH20_07LIST.uc < prev    next >
Encoding:
Text File  |  2006-02-28  |  908 b   |  37 lines

  1. // %PARAMETERS = "CH20LIST C:\UT2004"
  2. //Identifies the package
  3. //CH20_07LIST.uc
  4. //Test driver for the SoundProp class
  5.  
  6. class CH20_07LIST extends Commandlet;
  7. function int Main(string Args)
  8. {
  9.   //#1
  10.   local SoundProp firstProp;
  11.   firstProp = new class'SoundProp';
  12.  
  13.  
  14.   Log(Chr(10)$ " Testing the SoundProp class" $ Chr(10)  );
  15.  
  16.   //#2
  17.   firstProp.setName("Sirens.");
  18.   firstProp.setAction("Play");
  19.   firstProp.setPPos(2);
  20.   firstProp.setNumber(222);
  21.   firstProp.setPrimaryX(987
  22.   );
  23.  
  24.  
  25.   //#3
  26.   Log(Chr(10) $ "   Sound name: " $ firstProp.getName());
  27.   Log(Chr(10) $ "   Sound number: " $ firstProp.getNumber());
  28.   Log(Chr(10) $ "   Sound Play position: " $ firstProp.getPPos());
  29.   Log(Chr(10) $ "   getAction(): " $firstProp.getAction() ) ;
  30.  
  31.   //#4
  32.   //Call to the parent class (Prop)
  33.   Log(Chr(10) $ "   getPrimaryX: " $firstProp.getPrimaryX() ) ;
  34.   return 0;
  35.   return 0;
  36. }
  37.