2014-11-14 12:02:52 +01:00
/ *
* This file is part of Applied Energistics 2 .
* Copyright ( c ) 2013 - 2014 , AlgorithmX2 , All rights reserved .
*
* Applied Energistics 2 is free software : you can redistribute it and / or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation , either version 3 of the License , or
* ( at your option ) any later version .
*
* Applied Energistics 2 is distributed in the hope that it will be useful ,
* but WITHOUT ANY WARRANTY ; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE . See the
* GNU Lesser General Public License for more details .
*
* You should have received a copy of the GNU Lesser General Public License
* along with Applied Energistics 2 . If not , see < http : //www.gnu.org/licenses/lgpl>.
* /
2014-09-24 02:26:27 +02:00
package appeng.core.settings ;
2015-04-03 08:54:31 +02:00
2014-09-24 02:26:27 +02:00
import appeng.core.AEConfig ;
2015-04-03 08:54:31 +02:00
2014-09-24 02:26:27 +02:00
public enum TickRates
{
2015-04-03 08:54:31 +02:00
Interface ( 5 , 120 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
ImportBus ( 5 , 40 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
ExportBus ( 5 , 60 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
AnnihilationPlane ( 2 , 120 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
METunnel ( 5 , 20 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
Inscriber ( 1 , 1 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
IOPort ( 1 , 5 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
VibrationChamber ( 10 , 40 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
StorageBus ( 5 , 60 ) ,
2014-09-24 02:26:27 +02:00
2015-04-03 08:54:31 +02:00
ItemTunnel ( 5 , 60 ) ,
2014-09-24 02:26:27 +02:00
2015-05-07 23:03:32 +02:00
LightTunnel ( 5 , 120 ) ,
2015-08-05 17:00:35 +02:00
OpenComputersTunnel ( 1 , 5 ) ,
PressureTunnel ( 1 , 120 ) ;
2014-09-24 02:26:27 +02:00
public int min ;
public int max ;
2015-04-03 08:54:31 +02:00
TickRates ( int min , int max )
{
2014-09-24 02:26:27 +02:00
this . min = min ;
this . max = max ;
}
2015-04-03 08:54:31 +02:00
public void Load ( AEConfig config )
2014-09-24 02:26:27 +02:00
{
2015-04-03 08:54:31 +02:00
config . addCustomCategoryComment ( " TickRates " , " Min / Max Tickrates for dynamic ticking, most of these components also use sleeping, to prevent constant ticking, adjust with care, non standard rates are not supported or tested. " ) ;
2014-12-29 15:13:47 +01:00
this . min = config . get ( " TickRates " , this . name ( ) + " .min " , this . min ) . getInt ( this . min ) ;
this . max = config . get ( " TickRates " , this . name ( ) + " .max " , this . max ) . getInt ( this . max ) ;
2014-09-24 02:26:27 +02:00
}
}