5 string SOUND_RADIO_TURNED_ON =
"";
12 super.OnStoreSave( ctx );
15 ctx.Write( GetTunedFrequencyIndex() );
20 if ( !super.OnStoreLoad( ctx, version ) )
25 int tuned_frequency_idx;
26 if ( !ctx.Read( tuned_frequency_idx ) )
28 SetFrequencyByIndex( 0 );
31 SetFrequencyByIndex( tuned_frequency_idx );
37 override bool IsTransmitter()
43 void SetNextFrequency(
PlayerBase player = NULL )
84 override void OnSwitchOn()
86 if ( !GetCompEM().CanWork() )
88 GetCompEM().SwitchOff();
95 EnableBroadcast (
true );
96 EnableReceive (
true );
100 SoundTurnedOnNoiseStart();
106 GetCompEM().SwitchOff();
109 EnableBroadcast (
false );
110 EnableReceive (
false );
114 SoundTurnedOnNoiseStop();
121 protected void SoundTurnedOnNoiseStart()
123 PlaySoundSetLoop( m_SoundLoop, SOUND_RADIO_TURNED_ON, 1.0, 1.0 );
126 protected void SoundTurnedOnNoiseStop()
128 StopSoundSet( m_SoundLoop );