// Start is called before the first frame update void Start() { script = this.gameObject.GetComponent <GeneralFeatures>(); ringDetect = GameObject.Find("HitRing"); health = 3; player = GameObject.Find("Player"); dir = Random.Range(0, 4); EnemyAnimator = GetComponent <Animator>(); }
private ProgramFeatures(GeneralFeatures generalFeatures, FeatureCompatibility ntsc, FeatureCompatibility pal) { _features = new Dictionary <FeatureCategory, uint>(); CheckAccessSetFeatureBits(FeatureCategory.Ntsc, (uint)ntsc); CheckAccessSetFeatureBits(FeatureCategory.Pal, (uint)pal); CheckAccessSetFeatureBits(FeatureCategory.General, (uint)generalFeatures); CheckAccessSetFeatureBits(FeatureCategory.KeyboardComponent, (uint)KeyboardComponentFeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.SuperVideoArcade, (uint)FeatureCompatibility.Tolerates); CheckAccessSetFeatureBits(FeatureCategory.Intellivoice, (uint)FeatureCompatibility.Tolerates); CheckAccessSetFeatureBits(FeatureCategory.IntellivisionII, (uint)FeatureCompatibility.Tolerates); CheckAccessSetFeatureBits(FeatureCategory.Ecs, (uint)EcsFeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.Tutorvision, (uint)FeatureCompatibility.Tolerates); CheckAccessSetFeatureBits(FeatureCategory.Intellicart, (uint)IntellicartCC3FeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.CuttleCart3, (uint)CuttleCart3FeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.Jlp, (uint)JlpFeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.LtoFlash, (uint)LtoFlashFeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.Bee3, (uint)Bee3FeaturesHelpers.Default); CheckAccessSetFeatureBits(FeatureCategory.Hive, (uint)HiveFeaturesHelpers.Default); System.Diagnostics.Debug.Assert(_features.Count == (int)FeatureCategory.NumberOfCategories, "Failed to assign default features for all feature categories."); }
/// <inheritdoc /> public IProgramFeaturesBuilder WithGeneralFeatures(GeneralFeatures generalFeatures) { _programFeatures.GeneralFeatures = generalFeatures; return(this); }
public void IProgramInformationToXmlRomInformationConverter_ConvertInformationWithOneCrc_XmlRomInformationHasExpectedTypeString(GeneralFeatures generalFeatures, string expectedRomTypeString) { var features = new ProgramFeaturesBuilder().WithGeneralFeatures(generalFeatures).Build(); var information = new TestProgramInformation() { Title = "Rom Type tester info", Features = (ProgramFeatures)features }; information.AddCrcs(1, setVersionMetadata: false); var xmlRomInformation = IProgramInformationToXmlRomInformationConverter.Instance.Convert(information, convertAll: false, setFeatures: false, setMetadata: false).Single(); Assert.Equal(expectedRomTypeString, xmlRomInformation.GetColumn(XmlRomInformationDatabaseColumnName.type).Value); }
/// <summary> /// Creates a new instance if the UnmergedProgram structure. /// </summary> /// <param name="code">INTV Funhouse code for the ROM.</param> /// <param name="title">The title of the program (typically title screen title).</param> /// <param name="vendor">Vendor who wrote the program.</param> /// <param name="year">The year the program was copyrighted (or released).</param> /// <param name="crcData">The CRC values of known versions of the program.</param> /// <param name="crcDescriptions">The descriptions of the known versions of the program for each CRC.</param> /// <param name="generalFeatures">Generic program features.</param> /// <param name="cuttleCart3">Cuttle Cart 3 features.</param> internal UnmergedProgram(string code, string title, string vendor, string year, uint[] crcData, string[] crcDescriptions, GeneralFeatures generalFeatures, CuttleCart3Features cuttleCart3) { Code = code; CrcData = crcData; CrcDescriptions = crcDescriptions; CrcCfgs = Enumerable.Repeat(-1, crcData.Count()).ToArray(); Year = year; Title = title; Vendor = vendor; Features = new ProgramFeatures(); Features.GeneralFeatures = generalFeatures; Features.CuttleCart3 = cuttleCart3; }
/// <summary> /// Creates a new instance if the UnmergedProgram structure. /// </summary> /// <param name="code">INTV Funhouse code for the ROM.</param> /// <param name="title">The title of the program (typically title screen title).</param> /// <param name="vendor">Vendor who wrote the program.</param> /// <param name="year">The year the program was copyrighted (or released).</param> /// <param name="crcData">The CRC values of known versions of the program.</param> /// <param name="crcDescriptions">The descriptions of the known versions of the program for each CRC.</param> /// <param name="generalFeatures">Generic program features.</param> /// <param name="intellivoice">Intellivoice compatibility.</param> internal UnmergedProgram(string code, string title, string vendor, string year, uint[] crcData, string[] crcDescriptions, GeneralFeatures generalFeatures, FeatureCompatibility intellivoice) { Code = code; CrcData = crcData; CrcDescriptions = crcDescriptions; CrcCfgs = Enumerable.Repeat((generalFeatures == GeneralFeatures.SystemRom) ? -1 : 0, crcData.Count()).ToArray(); Year = year; Title = title; Vendor = vendor; Features = new ProgramFeatures(); Features.GeneralFeatures = generalFeatures; Features.Intellivoice = intellivoice; }
/// <summary> /// Creates a new instance if the UnmergedProgram structure. /// </summary> /// <param name="code">INTV Funhouse code for the ROM.</param> /// <param name="title">The title of the program (typically title screen title).</param> /// <param name="vendor">Vendor who wrote the program.</param> /// <param name="year">The year the program was copyrighted (or released).</param> /// <param name="crcData">The CRC values of known versions of the program.</param> /// <param name="crcDescriptions">The descriptions of the known versions of the program for each CRC.</param> /// <param name="generalFeatures">Generic program features.</param> /// <param name="keyboardComponent">Keyboard component features.</param> internal UnmergedProgram(string code, string title, string vendor, string year, uint[] crcData, string[] crcDescriptions, GeneralFeatures generalFeatures, KeyboardComponentFeatures keyboardComponent) { Code = code; CrcData = crcData; CrcDescriptions = crcDescriptions; CrcCfgs = Enumerable.Repeat(-1, crcData.Count()).ToArray(); Year = year; Title = title; Vendor = vendor; Features = new ProgramFeatures(); Features.GeneralFeatures = generalFeatures; Features.KeyboardComponent = keyboardComponent; }