1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

No Resouce?

Discussion in 'Bugs and Crashes' started by Hydromancerx, Aug 11, 2011.

  1. Hydromancerx

    Hydromancerx C2C Modder

    Joined:
    Feb 27, 2008
    Messages:
    16,281
    Location:
    California, USA
    So now that I converted the Culture "Goods" into Culture "Resources" I wanted to see how they worked. Native Cultures buildings give a free Culture "Resource" now. I first set it to unlimited but for some reason they do not show up in the city. So I though maybe i need to set it to a lower number like 1. But as you can see from the screenshot that the building is there but the resource is not.

    What's going on here? Why is it not working?
     
  2. Hydromancerx

    Hydromancerx C2C Modder

    Joined:
    Feb 27, 2008
    Messages:
    16,281
    Location:
    California, USA
    Here are examples of the code I used.

    Culture_CIV4ArtDefines_Bonus
    Spoiler :
    Code:
    		<BonusArtInfo>
    			<Type>ART_DEF_BONUS_AFRICAN</Type>
    			<fScale>1.0</fScale>
    			<fInterfaceScale>1.0</fInterfaceScale>
    			<NIF>Art/Empty.nif</NIF>
    			<KFM></KFM>
    			<Button>Modules/Hydro/Embassy/art/cultureafrican.dds</Button>
    			<FontButtonIndex>109</FontButtonIndex>
    		</BonusArtInfo>
    


    Culture_CIV4BonusInfos
    Spoiler :
    Code:
    		<BonusInfo>
    			<Type>BONUS_AFRICAN</Type>
    			<Description>TXT_KEY_BONUS_AFRICAN</Description>
    			<Civilopedia>TXT_KEY_BONUS_AFRICAN_PEDIA</Civilopedia>
    			<BonusClassType>BONUSCLASS_GENERAL</BonusClassType>
    			<ArtDefineTag>ART_DEF_BONUS_AFRICAN</ArtDefineTag>
    			<TechReveal>NONE</TechReveal>
    			<TechCityTrade>NONE</TechCityTrade>
    			<TechObsolete>NONE</TechObsolete>
    			<YieldChanges/>
    			<iAITradeModifier>0</iAITradeModifier>
    			<iAIObjective>0</iAIObjective>
    			<iHealth>0</iHealth>
    			<iHappiness>0</iHappiness>
    			<iPlacementOrder>-1</iPlacementOrder>
    			<iConstAppearance>0</iConstAppearance>
    			<iMinAreaSize>-1</iMinAreaSize>
    			<iMinLatitude>0</iMinLatitude>
    			<iMaxLatitude>90</iMaxLatitude>
    			<Rands>
    				<iRandApp1>0</iRandApp1>
    				<iRandApp2>0</iRandApp2>
    				<iRandApp3>0</iRandApp3>
    				<iRandApp4>0</iRandApp4>
    			</Rands>
    			<iPlayer>0</iPlayer>
    			<iTilesPer>0</iTilesPer>
    			<iMinLandPercent>0</iMinLandPercent>
    			<iUnique>0</iUnique>
    			<iGroupRange>0</iGroupRange>
    			<iGroupRand>0</iGroupRand>
    			<bArea>0</bArea>
    			<bHills>0</bHills>
    			<bFlatlands>0</bFlatlands>
    			<bNoRiverSide>0</bNoRiverSide>
    			<bNormalize>0</bNormalize>
    			<TerrainBooleans/>
    			<FeatureBooleans/>
    			<FeatureTerrainBooleans/>
    		</BonusInfo>
    


    Culture_CIV4BuildingInfos
    Spoiler :
    Code:
    		<BuildingInfo>
    			<BuildingClass>BUILDINGCLASS_CULTURE_HUMAN</BuildingClass>
    			<Type>BUILDING_CULTURE_AFRICAN</Type>
    			<SpecialBuildingType>NONE</SpecialBuildingType>
    			<Description>TXT_KEY_BUILDING_CULTURE_AFRICAN</Description>
    			<Civilopedia>TXT_KEY_BUILDING_CULTURE_AFRICAN_PEDIA</Civilopedia>
    			<Strategy>TXT_KEY_BUILDING_CULTURE_AFRICAN_STRATEGY</Strategy>
    			<Advisor>ADVISOR_CULTURE</Advisor>
    			<ArtDefineTag>ART_DEF_BUILDING_CULTURE_AFRICAN</ArtDefineTag>
    			<MovieDefineTag>NONE</MovieDefineTag>
    			<HolyCity>NONE</HolyCity>
    			<ReligionType>NONE</ReligionType>
    			<StateReligion>NONE</StateReligion>
    			<bStateReligion>0</bStateReligion>
    			<PrereqReligion>NONE</PrereqReligion>
    			<PrereqCorporation>NONE</PrereqCorporation>
    			<FoundsCorporation>NONE</FoundsCorporation>
    			<GlobalReligionCommerce>NONE</GlobalReligionCommerce>
    			<GlobalCorporationCommerce>NONE</GlobalCorporationCommerce>
    			<VictoryPrereq>NONE</VictoryPrereq>
    			<FreeStartEra>NONE</FreeStartEra>
    			<MaxStartEra>NONE</MaxStartEra>
    			<ObsoleteTech>NONE</ObsoleteTech>
    			<PrereqTech>NONE</PrereqTech>
    			<Bonus>NONE</Bonus>
    			<PrereqBonuses/>
    			<ProductionTraits/>
    			<HappinessTraits/>
    			<NoBonus>NONE</NoBonus>
    			<PowerBonus>NONE</PowerBonus>
    			<FreeBonus>BONUS_AFRICAN</FreeBonus>
    			<iNumFreeBonuses>1</iNumFreeBonuses>
    			<FreeBuilding>NONE</FreeBuilding>
    			<FreePromotion>NONE</FreePromotion>
    			<CivicOption>NONE</CivicOption>
    			<GreatPeopleUnitClass>NONE</GreatPeopleUnitClass>
    			<iGreatPeopleRateChange>0</iGreatPeopleRateChange>
    			<iHurryAngerModifier>0</iHurryAngerModifier>
    			<bBorderObstacle>0</bBorderObstacle>
    			<bTeamShare>0</bTeamShare>
    			<bWater>0</bWater>
    			<bRiver>0</bRiver>
    			<bPower>0</bPower>
    			<bDirtyPower>0</bDirtyPower>
    			<bAreaCleanPower>0</bAreaCleanPower>
    			<DiploVoteType>NONE</DiploVoteType>
    			<bForceTeamVoteEligible>0</bForceTeamVoteEligible>
    			<bCapital>0</bCapital>
    			<bGovernmentCenter>0</bGovernmentCenter>
    			<bGoldenAge>0</bGoldenAge>
    			<bAllowsNukes>0</bAllowsNukes>
    			<bMapCentering>0</bMapCentering>
    			<bNoUnhappiness>0</bNoUnhappiness>
    			<bNoUnhealthyPopulation>0</bNoUnhealthyPopulation>
    			<bBuildingOnlyHealthy>0</bBuildingOnlyHealthy>
    			<bNeverCapture>0</bNeverCapture>
    			<bNukeImmune>0</bNukeImmune>
    			<bPrereqReligion>0</bPrereqReligion>
    			<bCenterInCity>0</bCenterInCity>
    			<iAIWeight>100</iAIWeight>
    			<iCost>5</iCost>
    			<iHurryCostModifier>100</iHurryCostModifier>
    			<iAdvancedStartCost>-1</iAdvancedStartCost>
    			<iAdvancedStartCostIncrease>0</iAdvancedStartCostIncrease>
    			<iMinAreaSize>-1</iMinAreaSize>
    			<iConquestProb>0</iConquestProb>
    			<iCitiesPrereq>0</iCitiesPrereq>
    			<iTeamsPrereq>0</iTeamsPrereq>
    			<iLevelPrereq>0</iLevelPrereq>
    			<iMinLatitude>0</iMinLatitude>
    			<iMaxLatitude>90</iMaxLatitude>
    			<iGreatPeopleRateModifier>0</iGreatPeopleRateModifier>
    			<iGreatGeneralRateModifier>0</iGreatGeneralRateModifier>
    			<iDomesticGreatGeneralRateModifier>0</iDomesticGreatGeneralRateModifier>
    			<iGlobalGreatPeopleRateModifier>0</iGlobalGreatPeopleRateModifier>
    			<iAnarchyModifier>0</iAnarchyModifier>
    			<iGoldenAgeModifier>0</iGoldenAgeModifier>
    			<iGlobalHurryModifier>0</iGlobalHurryModifier>
    			<iExperience>0</iExperience>
    			<iGlobalExperience>0</iGlobalExperience>
    			<iFoodKept>0</iFoodKept>
    			<iAirlift>0</iAirlift>
    			<iAirModifier>0</iAirModifier>
    			<iAirUnitCapacity>0</iAirUnitCapacity>
    			<iNukeModifier>0</iNukeModifier>
    			<iNukeExplosionRand>0</iNukeExplosionRand>
    			<iFreeSpecialist>0</iFreeSpecialist>
    			<iAreaFreeSpecialist>0</iAreaFreeSpecialist>
    			<iGlobalFreeSpecialist>0</iGlobalFreeSpecialist>
    			<iMaintenanceModifier>0</iMaintenanceModifier>
    			<iWarWearinessModifier>0</iWarWearinessModifier>
    			<iGlobalWarWearinessModifier>0</iGlobalWarWearinessModifier>
    			<iEnemyWarWearinessModifier>0</iEnemyWarWearinessModifier>
    			<iHealRateChange>0</iHealRateChange>
    			<iHealth>0</iHealth>
    			<iAreaHealth>0</iAreaHealth>
    			<iGlobalHealth>0</iGlobalHealth>
    			<iHappiness>0</iHappiness>
    			<iAreaHappiness>0</iAreaHappiness>
    			<iGlobalHappiness>0</iGlobalHappiness>
    			<iStateReligionHappiness>0</iStateReligionHappiness>
    			<iWorkerSpeedModifier>0</iWorkerSpeedModifier>
    			<iMilitaryProductionModifier>0</iMilitaryProductionModifier>
    			<iSpaceProductionModifier>0</iSpaceProductionModifier>
    			<iGlobalSpaceProductionModifier>0</iGlobalSpaceProductionModifier>
    			<iTradeRoutes>0</iTradeRoutes>
    			<iCoastalTradeRoutes>0</iCoastalTradeRoutes>
    			<iGlobalTradeRoutes>0</iGlobalTradeRoutes>
    			<iTradeRouteModifier>0</iTradeRouteModifier>
    			<iForeignTradeRouteModifier>0</iForeignTradeRouteModifier>
    			<iGlobalPopulationChange>0</iGlobalPopulationChange>
    			<iFreeTechs>0</iFreeTechs>
    			<iDefense>0</iDefense>
    			<iBombardDefense>0</iBombardDefense>
    			<iAllCityDefense>0</iAllCityDefense>
    			<iEspionageDefense>0</iEspionageDefense>
    			<iAsset>0</iAsset>
    			<iPower>0</iPower>
    			<fVisibilityPriority>0.0</fVisibilityPriority>
    			<SeaPlotYieldChanges/>
    			<RiverPlotYieldChanges/>
    			<GlobalSeaPlotYieldChanges/>
    			<YieldChanges>
    				<iYield>0</iYield>
    				<iYield>0</iYield>
    				<iYield>0</iYield>
    			</YieldChanges>
    			<CommerceChanges>
    				<iCommerce>0</iCommerce>
    				<iCommerce>0</iCommerce>
    				<iCommerce>1</iCommerce>
    				<iCommerce>0</iCommerce>
    			</CommerceChanges>
    			<ObsoleteSafeCommerceChanges>
    				<iCommerce>0</iCommerce>
    				<iCommerce>0</iCommerce>
    				<iCommerce>0</iCommerce>
    			</ObsoleteSafeCommerceChanges>
    			<CommerceChangeDoubleTimes/>
    			<CommerceModifiers/>
    			<GlobalCommerceModifiers/>
    			<SpecialistExtraCommerces/>
    			<StateReligionCommerces/>
    			<CommerceHappinesses/>
    			<ReligionChanges/>
    			<SpecialistCounts/>
    			<FreeSpecialistCounts/>
    			<CommerceFlexibles/>
    			<CommerceChangeOriginalOwners/>
    			<ConstructSound/>
    			<BonusHealthChanges/>
    			<BonusHappinessChanges/>
    			<BonusProductionModifiers/>
    			<UnitCombatFreeExperiences/>
    			<DomainFreeExperiences/>
    			<DomainProductionModifiers/>
    			<BuildingHappinessChanges/>
    			<PrereqBuildingClasses/>
    			<BuildingClassNeededs/>
    			<SpecialistYieldChanges/>
    			<BonusYieldModifiers/>
    			<ImprovementFreeSpecialists/>
    			<Flavors/>
    			<HotKey/>
    			<bAltDown>0</bAltDown>
    			<bShiftDown>0</bShiftDown>
    			<bCtrlDown>0</bCtrlDown>
    			<iHotKeyPriority>0</iHotKeyPriority>
    		</BuildingInfo>
    


    Is there anything that looks wrong here?
     
  3. Koshling

    Koshling Vorlon

    Joined:
    Apr 11, 2011
    Messages:
    9,254
    Can you post the actual files and I'll run it through under the debugger and see if I can spot what's going on.
     
  4. Hydromancerx

    Hydromancerx C2C Modder

    Joined:
    Feb 27, 2008
    Messages:
    16,281
    Location:
    California, USA
    Its already on the SVN under Modules/Hydro/Embassy. I uploaded it before I knew of this problem.

    At the moment you cannot make any local culture building since the resources don't show up.

    Anywho here are the files anyways (with a minor tweak from -1 to 1 in the free resource amount field).
     
  5. strategyonly

    strategyonly C2C Supreme Commander

    Joined:
    Mar 13, 2006
    Messages:
    20,445
    Gender:
    Male
    Location:
    MN
    Take a look at Bonus_Ammo or Bonus_Biofuel these are good examples of the way it should be done.
     
  6. Hydromancerx

    Hydromancerx C2C Modder

    Joined:
    Feb 27, 2008
    Messages:
    16,281
    Location:
    California, USA
    I used those, specifically Bonus_Music as my template.
     
  7. Hydromancerx

    Hydromancerx C2C Modder

    Joined:
    Feb 27, 2008
    Messages:
    16,281
    Location:
    California, USA
    Without changing anything it now sort of works. You see I bought a city from England and build "Native Culture (European)" building which gave me "European Culture" Resource. You can see the culture is showing up in city screen. I cannot get it in my other cities because apparently I cannot trade resources over the ocean yet.

    I should just try a new game and see if its just a saved game bug where new resources don't work right even with maximum compatibility saves.

    EDIT: Yep it was the game. I made a new game and now it shows up.

    However anyone know how to get the little icon to show up in the city screen? My resource just shows up as big text.
     
  8. Dancing Hoskuld

    Dancing Hoskuld Warlord

    Joined:
    Jul 5, 2004
    Messages:
    23,290
    Gender:
    Male
    Location:
    Canberra, Australia
    That is the limit problem again, but not as bad as it was. That part of the screen comes from the font 75 file.
     
  9. Schwarzbart

    Schwarzbart Chieftain

    Joined:
    Jul 21, 2009
    Messages:
    509
    So for the missing Walrus Icon in the city view its the same reason?
     
  10. Dancing Hoskuld

    Dancing Hoskuld Warlord

    Joined:
    Jul 5, 2004
    Messages:
    23,290
    Gender:
    Male
    Location:
    Canberra, Australia
    Yes. At least it is only the missing icon and large text in that part of the screen which is being affected now. Rather than fonts and icons everywhere being swapped.
     
  11. Koshling

    Koshling Vorlon

    Joined:
    Apr 11, 2011
    Messages:
    9,254
    I'll look and see if I can find the hole in the save/load that would explain this. Might be that free resources are not being translatred or something

    Edit - I can't see any issues with the remapping of these free resources in the save/load, but if you still have a save game that shows it please post it for me to look at (with a short commentary about what city to look in and the specifics of which building/resource are involved in the case the save game demonstrates). I realise you've got this working in a new ganme, but for the sake of heading off issues for those people that continue games since you have an example it would be good to fully understand it.
     

Share This Page