Seite 101 von 180 ErsteErste ... 5191979899100101102103104105111151 ... LetzteLetzte
Ergebnis 1.501 bis 1.515 von 2699

Thema: Der SDK-Fragen-Thread

  1. #1501
    Civ4 BASE Coder Avatar von rucivfan
    Registriert seit
    10.07.11
    Ort
    Antarktika
    Beiträge
    19.016
    Einrückungen spielen in C++ keine Rolle. Sie dienen nur des schöneren Lesens.

    es heißt plot() und nicht nur plot. plot() ist eine Funktion, die dir den Plot mit einen Zeiger gibt.

    Für was steht dort "int CvUnit::getplot() const" ?

  2. #1502
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Für was steht dort "int CvUnit::getplot() const
    Ich dachte das wäre der Zeiger...
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  3. #1503
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Fehlermeldung beim kompilieren

    1>CvUnit.cpp(6042) : error C2065: 'bUpdatePlotGroups' : undeclared identifier
    1>CvUnit.cpp(13435) : error C2664: 'CvPlot::isPlotGroupConnectedBonus' : cannot convert parameter 2 from 'int' to 'BonusTypes'
    1> Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    1>CvUnit.cpp(13436) : error C2143: syntax error : missing ')' before '{'



    Code:
    if (GC.getPromotionInfo(ePromotion).getBonusPrereq() != NO_BONUS)
    	{
    		if (!plot()->isPlotGroupConnectedBonus( getOwnerINLINE(), GC.getPromotionInfo(ePromotion).getBonusPrereq()) 
    		{
    			return false;
    		}
    	}
    Es ist doch verhext!
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  4. #1504
    Civ4 BASE Coder Avatar von rucivfan
    Registriert seit
    10.07.11
    Ort
    Antarktika
    Beiträge
    19.016
    1. Beim ersten Fehler ist es was ganz anders, wie du an der Fehlerzeile siehst. Falls du es noch nicht mitbekommen hast, die Nummern sind Zeilenangaben.

    2. if (!plot()->isPlotGroupConnectedBonus( getOwnerINLINE(), (BonusTypes)GC.getPromotionInfo(ePromotion).getBonusPrereq())

    Hintergrund: getBonusPrereq() gibt einen Integer wieder und isPlotGroupConnectedBonus will einen Enumeration Names BonusTypes. Dahinter steckt einfach ein Integer. Enumeration werden verwendet um verschiedene Integer zu unterscheiden.

    3. Es fehlt eine schließene Klammer hinter if (!plot()->isPlotGroupConnectedBonus( getOwnerINLINE(), (BonusTypes)GC.getPromotionInfo(ePromotion).getBonusPrereq()) )

  5. #1505
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Merci!!! Wieder einmal!!! Auch der Pythonteil funzt! Danke Rucivfan!

    Es muss belastend sein sich mit Leuten wir mir rum ärgern zu müssen!

    Aber ich werde auf jeden fall mal mehr lesen was das Thema C++ angeht.
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  6. #1506
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Bin am Debuggen...

    1)

    Assert Failed

    File: CvUnit.cpp
    Line: 11137
    Expression: !at(iX, iY)
    Message:

    ----------------------------------------------------------


    Code:
    void CvUnit::setXY(int iX, int iY, bool bGroup, bool bUpdate, bool bShow, bool bCheckPlotVisible)
    {
    	CLLNode<IDInfo>* pUnitNode;
    	CvCity* pOldCity;
    	CvCity* pNewCity;
    	CvCity* pWorkingCity;
    	CvUnit* pTransportUnit;
    	CvUnit* pLoopUnit;
    	CvPlot* pOldPlot;
    	CvPlot* pNewPlot;
    	CvPlot* pLoopPlot;
    	CLinkList<IDInfo> oldUnits;
    	ActivityTypes eOldActivityType;
    	int iI;
    
    	// OOS!! Temporary for Out-of-Sync madness debugging...
    	if (GC.getLogging())
    	{
    		if (gDLL->getChtLvl() > 0)
    		{
    			char szOut[1024];
    			sprintf(szOut, "Player %d Unit %d (%S's %S) moving from %d:%d to %d:%d\n", getOwnerINLINE(), getID(), GET_PLAYER(getOwnerINLINE()).getNameKey(), getName().GetCString(), getX_INLINE(), getY_INLINE(), iX, iY);
    			gDLL->messageControlLog(szOut);
    		}
    	}
    
    	FAssert(!at(iX, iY));                 <<<<
    	FAssert(!isFighting());
    	FAssert((iX == INVALID_PLOT_COORD) || (GC.getMapINLINE().plotINLINE(iX, iY)->getX_INLINE() == iX));
    	FAssert((iY == INVALID_PLOT_COORD) || (GC.getMapINLINE().plotINLINE(iX, iY)->getY_INLINE() == iY));


    2)

    Assert Failed

    File: CvUnit.cpp
    Line: 11637
    Expression: pOldPlot != pNewPlot
    Message:

    ----------------------------------------------------------


    Code:
    if (bUpdate && hasCargo())
    	{
    		if (pOldPlot != NULL)
    		{
    			pOldPlot->updateCenterUnit();
    			pOldPlot->setFlagDirty(true);
    		}
    
    		if (pNewPlot != NULL)
    		{
    			pNewPlot->updateCenterUnit();
    			pNewPlot->setFlagDirty(true);
    		}
    	}
    
    	FAssert(pOldPlot != pNewPlot);                                      <<<<<<
    	GET_PLAYER(getOwnerINLINE()).updateGroupCycle(this);
    
    	setInfoBarDirty(true);

    3)

    Assert Failed

    File: CvPlayer.cpp
    Line: 7063
    Expression: GC.getCivilizationInfo(getCivilizationType()).getCivilizationUnits(eUnitClass) == eUnit
    Message:

    ----------------------------------------------------------

    Code:
    bool CvPlayer::canTrain(UnitTypes eUnit, bool bContinue, bool bTestVisible, bool bIgnoreCost) const
    {
    	PROFILE_FUNC();
    
    	UnitClassTypes eUnitClass;
    	int iI;
    
    	eUnitClass = ((UnitClassTypes)(GC.getUnitInfo(eUnit).getUnitClassType()));
    
    	FAssert(GC.getCivilizationInfo(getCivilizationType()).getCivilizationUnits(eUnitClass) == eUnit);       <<<<<
    	if (GC.getCivilizationInfo(getCivilizationType()).getCivilizationUnits(eUnitClass) != eUnit)
    	{
    		return false;
    	}



    4)

    Assert Failed

    File: CvUnitAI.cpp
    Line: 11611
    Expression: canDefend()
    Message:

    ----------------------------------------------------------


    Code:
    bool CvUnitAI::AI_guardCity(bool bLeave, bool bSearch, int iMaxPath)
    {
    	PROFILE_FUNC();
    
    	CLLNode<IDInfo>* pUnitNode;
    	CvCity* pCity;
    	CvCity* pLoopCity;
    	CvUnit* pLoopUnit;
    	CvPlot* pPlot;
    	CvPlot* pBestPlot;
    	CvPlot* pBestGuardPlot;
    	bool bDefend;
    	int iExtra;
    	int iCount;
    	int iPathTurns;
    	int iValue;
    	int iBestValue;
    	int iLoop;
    
    	FAssert(getDomainType() == DOMAIN_LAND);
    	FAssert(canDefend());      <<<<<<
    
    	pPlot = plot();
    	pCity = pPlot->getPlotCity();

    Das ist es was ich nach 80 Runden bekommen habe
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  7. #1507
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Ui, hier ist er direkt in VC gesprungen!


    Run-Time Check Failure #3 - The variable 'pBestPlot' is being used without being defined.


    Code:
    CvCity* pLoopCity;
    	CvPlot* pBestPlot;
    	CvPlot* pCityPlot;
    	int iLoop;
    	int iPathTurns;
    	for (pLoopCity = GET_PLAYER(getOwnerINLINE()).firstCity(&iLoop); pLoopCity != NULL; pLoopCity = GET_PLAYER(getOwnerINLINE()).nextCity(&iLoop))
    	{
    		if( pLoopCity->isBlockadedOnWater() )
    		{
    			pCityPlot = pLoopCity->plot();
    			if (generatePath(pCityPlot, 0, true, &iPathTurns))
    			{
    				pBestPlot = getPathEndTurnPlot();
    			}
    			if ((pBestPlot != NULL) && (pCityPlot != NULL) && iPathTurns < 5)      <<<<<
    			{
    				if (atPlot(pCityPlot))
    				{
    					int iAttackers = pCityPlot->plotCount(PUF_isUnitAIType, UNITAI_ATTACK_SEA, -1 /*rucivfan[*/, NULL /*]rucivfan*/, NO_PLAYER, getTeam(), PUF_isGroupHead, -1, -1);
    					int iBlockaders = GET_PLAYER(getOwnerINLINE()).AI_getWaterDanger(pCityPlot, 4);
    					if( iAttackers > (iBlockaders + 2) )
    					{
    						if( iAttackers > GC.getGameINLINE().getSorenRandNum(2*iBlockaders + 1, "AI - Break blockade") )

    Call Stack

    > CvGameCoreDLL.dll!CvUnitAI::AI_attackSeaMove() Line 6381 + 0x10 bytes C++
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  8. #1508
    Civ4 BASE Coder Avatar von rucivfan
    Registriert seit
    10.07.11
    Ort
    Antarktika
    Beiträge
    19.016
    Beim Letzten: Da war ja eine Intelligenzbestie am Werk. (" Added for Planetfall")

    Setze über if (generatePath(pCityPlot, 0, true, &iPathTurns)) einmal pBestPlot = NULL;. Wenn ich noch was wichtiges See, editiere ich es.

    1.) Das hatte ich auch immer beim Testen, konnte es nicht lokalisieren.

    2.) Ist ein Folgefehler von Fehler Nummer 1.

    3.) Kenn ich auch vom Testen. Kann ignoriert werden.

    Code:
    	if (GC.getCivilizationInfo(getCivilizationType()).getCivilizationUnits(eUnitClass) != eUnit)
    	{
    		return false;
    	}
    	FAssert(GC.getCivilizationInfo(getCivilizationType()).getCivilizationUnits(eUnitClass) == eUnit);
    Setze den Fassert einfach nach der if-Abfrage oder entferne ihn.

    4.) Hatte ich auch, kann aber nicht harmlos unter umständen sein. Es besitzt eine Einheit ohne Kampffähigkeit jedoch eine Kampfki, die in der Civ4UnitInfo eingetragen ist.
    Geändert von rucivfan (15. Mai 2014 um 21:45 Uhr)

  9. #1509
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Zitat Zitat von rucivfan Beitrag anzeigen

    Setze über if (generatePath(pCityPlot, 0, true, &iPathTurns)) einmal pBestPlot = NULL;. Wenn ich noch was wichtiges See, editiere ich es.
    Also so...

    Code:
    CvCity* pLoopCity;
    	CvPlot* pBestPlot;
    	CvPlot* pCityPlot;
    	int iLoop;
    	int iPathTurns;
    	for (pLoopCity = GET_PLAYER(getOwnerINLINE()).firstCity(&iLoop); pLoopCity != NULL; pLoopCity = GET_PLAYER(getOwnerINLINE()).nextCity(&iLoop))
    	{
    		if( pLoopCity->isBlockadedOnWater() )
    		{
    			pCityPlot = pLoopCity->plot();
                            pBestPlot = NULL;
    			if (generatePath(pCityPlot, 0, true, &iPathTurns))
    			{
    				pBestPlot = getPathEndTurnPlot();
    			}
    			if ((pBestPlot != NULL) && (pCityPlot != NULL) && iPathTurns < 5)      <<<<<
    			{
    				if (atPlot(pCityPlot))
    				{
    					int iAttackers = pCityPlot->plotCount(PUF_isUnitAIType, UNITAI_ATTACK_SEA, -1 /*rucivfan[*/, NULL /*]rucivfan*/, NO_PLAYER, getTeam(), PUF_isGroupHead, -1, -1);
    					int iBlockaders = GET_PLAYER(getOwnerINLINE()).AI_getWaterDanger(pCityPlot, 4);
    					if( iAttackers > (iBlockaders + 2) )
    					{
    						if( iAttackers > GC.getGameINLINE().getSorenRandNum(2*iBlockaders + 1, "AI - Break blockade") )

    4.) Hatte ich auch, kann aber nicht harmlos unter umständen sein. Es besitzt eine Einheit ohne Kampffähigkeit jedoch eine Kampfki, die in der Civ4UnitInfo eingetragen ist.
    Dann werd ich mal gucken was ich in der UnitInfo finde, also so eine Art Bautrupp der Kämpfen muss...
    Geändert von Monaldinio (15. Mai 2014 um 21:58 Uhr)
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  10. #1510
    Moderator Avatar von Kathy
    Registriert seit
    11.10.07
    Beiträge
    17.017
    Ich hab versucht, einen Code für den Verbrauch von Ressourcen durch die Erstentwicklung einer Technologie ins SDK zu übertragen. Leider stürzt das Programm immer ab. Ist hier irgendwo ein offensichtlicher Fehler drin, den ich nur übersehe?
    Code:
    void CvTeam::setHasTech(TechTypes eIndex, bool bNewValue, PlayerTypes ePlayer, bool bFirst, bool bAnnounce)
    {
    	PROFILE_FUNC();
    
    	CvCity* pCapitalCity;
    	CvCity* pCity;
    	CvPlot* pLoopPlot;
    	CvWString szBuffer;
    	CivicOptionTypes eCivicOptionType;
    	CivicTypes eCivicType;
    	PlayerTypes eBestPlayer;
    	BonusTypes eBonus;
    	UnitTypes eFreeUnit;
    	bool bReligionFounded;
    	bool bFirstBonus;
    	int iValue;
    	int iBestValue;
    	int iI, iJ, iK;
    
    	if (eIndex == NO_TECH)
    	{
    		return;
    	}
    
    	if (ePlayer == NO_PLAYER)
    	{
    		ePlayer = getLeaderID();
    	}
    
    	FAssertMsg(eIndex >= 0, "eIndex is expected to be non-negative (invalid Index)");
    	FAssertMsg(eIndex < GC.getNumTechInfos(), "eIndex is expected to be within maximum bounds (invalid Index)");
    	FAssertMsg(ePlayer >= 0, "eIndex is expected to be non-negative (invalid Index)");
    	FAssertMsg(ePlayer < MAX_PLAYERS, "ePlayer is expected to be within maximum bounds (invalid Index)");
    
    	if (isHasTech(eIndex) != bNewValue)
    	{
    		if (GC.getTechInfo(eIndex).isRepeat())
    		{
    			m_paiTechCount[eIndex]++;
    
    			setResearchProgress(eIndex, 0, ePlayer);
    
    			// report event to Python
    			CvEventReporter::getInstance().techAcquired(eIndex, getID(), ePlayer, bAnnounce && 1 == m_paiTechCount[eIndex]);
    
    			if (1 == m_paiTechCount[eIndex])
    			{
    				if (bAnnounce)
    				{
    					if (GC.getGameINLINE().isFinalInitialized() && !(gDLL->GetWorldBuilderMode()))
    					{
    						announceTechToPlayers(eIndex);
    					}
    				}
    			}
    		}
    		else
    		{
    			for (iI = 0; iI < GC.getMapINLINE().numPlotsINLINE(); iI++)
    			{
    				pLoopPlot = GC.getMapINLINE().plotByIndexINLINE(iI);
    
    				if (pLoopPlot->getBonusType() != NO_BONUS)
    				{
    					if (pLoopPlot->getTeam() == getID())
    					{
    						if ((GC.getBonusInfo(pLoopPlot->getBonusType()).getTechReveal() == eIndex) ||
    							  (GC.getBonusInfo(pLoopPlot->getBonusType()).getTechCityTrade() == eIndex) ||
    								(GC.getBonusInfo(pLoopPlot->getBonusType()).getTechObsolete() == eIndex))
    						{
    							pLoopPlot->updatePlotGroupBonus(false);
    						}
    					}
    				}
    			}
    
    			m_pabHasTech[eIndex] = bNewValue;
    
    			for (iI = 0; iI < GC.getMapINLINE().numPlotsINLINE(); iI++)
    			{
    				pLoopPlot = GC.getMapINLINE().plotByIndexINLINE(iI);
    
    				if (pLoopPlot->getBonusType() != NO_BONUS)
    				{
    					if (pLoopPlot->getTeam() == getID())
    					{
    						if ((GC.getBonusInfo(pLoopPlot->getBonusType()).getTechReveal() == eIndex) ||
    							  (GC.getBonusInfo(pLoopPlot->getBonusType()).getTechCityTrade() == eIndex) ||
    							  (GC.getBonusInfo(pLoopPlot->getBonusType()).getTechObsolete() == eIndex))
    						{
    							pLoopPlot->updatePlotGroupBonus(true);
    						}
    					}
    				}
    			}
    		}
    
    		processTech(eIndex, ((bNewValue) ? 1 : -1));
    
    		if (isHasTech(eIndex))
    		{
    /************************************************************************************************/
    /* BETTER_BTS_AI_MOD                      10/02/09                                jdog5000      */
    /*                                                                                              */
    /* AI logging                                                                                   */
    /************************************************************************************************/
    			if( gTeamLogLevel >= 2 )
    			{
    				logBBAI("    Team %d (%S) acquires tech %S", getID(), GET_PLAYER(getLeaderID()).getCivilizationDescription(0), GC.getTechInfo(eIndex).getDescription() );
    			}
    /************************************************************************************************/
    /* BETTER_BTS_AI_MOD                       END                                                  */
    /************************************************************************************************/
    
    			for (iI = 0; iI < MAX_PLAYERS; iI++)
    			{
    				if (GET_PLAYER((PlayerTypes)iI).getTeam() == getID())
    				{
    					if (GET_PLAYER((PlayerTypes)iI).getCurrentEra() < GC.getTechInfo(eIndex).getEra())
    					{
    						GET_PLAYER((PlayerTypes)iI).setCurrentEra((EraTypes)(GC.getTechInfo(eIndex).getEra()));
    					}
    				}
    			}
    //Hier steht weiterer, unveränderter Code
    			//Kathy Tech verbraucht Bonus Beginn
    			if (bFirst)
    			{
    				if (GC.getGameINLINE().countKnownTechNumTeams(eIndex) == 1)
    				{
    					int iBonus;
    					int iNumBonus;
    					iNumBonus = GC.getNumBonusClassInfos();
    					BonusTypes eBonusConsume;
    
    					for (iBonus; iBonus< iNumBonus; iBonus++)
    					{
    						eBonusConsume = (BonusTypes)(iBonus);
    						if ( eBonusConsume != NO_BONUS )
    						{
    							if ( GC.getBonusInfo(eBonusConsume).getTechConsume() == eIndex)
    							{
    								std::vector<CvPlot*> aBonusPlots;
    								for (iI = 0; iI < GC.getMapINLINE().numPlotsINLINE(); iI++)
    								{
    									pLoopPlot = GC.getMapINLINE().plotByIndexINLINE(iI);
    
    									if (pLoopPlot->getTeam() == getID())
    									{
    										eBonus = pLoopPlot->getBonusType();
    
    										if (eBonus == eBonusConsume)
    										{
    											aBonusPlots.push_back(pLoopPlot);
    												
    										}
    									}
    								}
    								if (aBonusPlots.size() > 0)
    								{
    									CvPlot* pConsumePlot;
    									int iHalfLength;
    									iHalfLength = aBonusPlots.size()/2;
    									pConsumePlot = aBonusPlots[iHalfLength];
    
    									if (pConsumePlot != NULL)
    									{
    										pConsumePlot->setBonusType(NO_BONUS);
    											
    										pCity =	GC.getMapINLINE().findCity(pConsumePlot->getX_INLINE(), pConsumePlot->getY_INLINE(), NO_PLAYER, getID(), false);
    										
    										if (pCity != NULL)
    										{
    											szBuffer = gDLL->getText("TXT_KEY_INFO_TECH_BONUS_LOSS", GC.getBonusInfo(eBonusConsume).getTextKeyWide(), pCity->getNameKey());
    											gDLL->getInterfaceIFace()->addMessage(pConsumePlot->getOwnerINLINE(), false, GC.getEVENT_MESSAGE_TIME(), szBuffer, "AS2D_DISCOVERBONUS", MESSAGE_TYPE_INFO, GC.getBonusInfo(eBonusConsume).getButton(), (ColorTypes)GC.getInfoTypeForString("COLOR_RED"), pConsumePlot->getX_INLINE(), pConsumePlot->getY_INLINE(), true, true);
    										}
    									}
    								}
    							}
    						}
    					}
    				}
    			}//Edit: korrektur 2
    
    			//Kathy Tech verbraucht Bonus End
    //Hier steht weiterer, unveränderter Code
    		if (bNewValue)
    		{
    			if (bAnnounce)
    			{
    				if (GC.getGameINLINE().isFinalInitialized() && !(gDLL->GetWorldBuilderMode()))
    				{
    					FAssert(ePlayer != NO_PLAYER);
    					if (GET_PLAYER(ePlayer).isResearch() && (GET_PLAYER(ePlayer).getCurrentResearch() == NO_TECH))
    					{
    						szBuffer = gDLL->getText("TXT_KEY_MISC_WHAT_TO_RESEARCH_NEXT");
    						GET_PLAYER(ePlayer).chooseTech(0, szBuffer);
    					}
    				}
    			}
    		}
    
    		if (getID() == GC.getGameINLINE().getActiveTeam())
    		{
    			gDLL->getInterfaceIFace()->setDirty(MiscButtons_DIRTY_BIT, true);
    			gDLL->getInterfaceIFace()->setDirty(SelectionButtons_DIRTY_BIT, true);
    			gDLL->getInterfaceIFace()->setDirty(ResearchButtons_DIRTY_BIT, true);
    			gDLL->getInterfaceIFace()->setDirty(GlobeLayer_DIRTY_BIT, true);
    		}
    	}
    }
    Neu ist der rote Teil in dem Block.
    Geändert von Kathy (16. Mai 2014 um 14:50 Uhr)

  11. #1511
    Civ4 BASE Coder Avatar von rucivfan
    Registriert seit
    10.07.11
    Ort
    Antarktika
    Beiträge
    19.016
    "for (iBonus; iBonus< iNumBonus; iBonus++)" hust hust iBonus wird nirgends gesetzt hust hust.
    Geändert von rucivfan (19. Mai 2014 um 09:29 Uhr)

  12. #1512
    Moderator Avatar von Kathy
    Registriert seit
    11.10.07
    Beiträge
    17.017
    Danke, Rucivfan. Ich teste es gleich.

    Edit: Jetzt funktioniert es. Danke noch einmal.
    Geändert von Kathy (16. Mai 2014 um 15:22 Uhr)

  13. #1513
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Ich habe mal eine , es geht um das Gitternetz das auf der Karte eingeblendet wird...

    Wäre es möglich noch ein zweites Gitternetzt darstellen zu lassen,auch mit an/aus Button, das ich der Höhe verschoben ist?!?! Ich mein, Einheiten kann man ja auch in der Nif datei in der Höhe verschieben...
    So ungefähr so stelle ich mir das vor...siehe Anhang.
    Dazu müsste ich doch theoretisch nur den Code den ersten Gitternetz finden, kopieren...und anpassen oder?!!?


    Bild
    Angehängte Grafiken Angehängte Grafiken
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

  14. #1514
    Civ4 BASE Coder Avatar von rucivfan
    Registriert seit
    10.07.11
    Ort
    Antarktika
    Beiträge
    19.016
    Frage:

    Gibt es eine Möglichkeit, mehr als nur einfach Rückgabewerte vom SDK an Python zu übergeben? Konkret bräuchte ich eine Liste in Python, die ich im SDK generiere. Zu Zeit überlege ich diese mit einen Vector zu generieren, aber das dürfte schwer sein, dass so in Python zu übergeben, oder? Habe ich vielleicht was übersehen und es gibt ein Beispiel im Code?




    Zitat Zitat von Monaldinio Beitrag anzeigen
    Ich habe mal eine , es geht um das Gitternetz das auf der Karte eingeblendet wird...

    Wäre es möglich noch ein zweites Gitternetzt darstellen zu lassen,auch mit an/aus Button, das ich der Höhe verschoben ist?!?! Ich mein, Einheiten kann man ja auch in der Nif datei in der Höhe verschieben...
    So ungefähr so stelle ich mir das vor...siehe Anhang.
    Dazu müsste ich doch theoretisch nur den Code den ersten Gitternetz finden, kopieren...und anpassen oder?!!?
    Ich weiß nicht, ob man das machen kann. Ich kann nur vermuten, dass man im Pythoncode das entsprechende GUI Element für das Gitter finden könnte und das man schaut, was ruft es auf und wie funktioniert es.

    Schließlich wird die gesamte GUI in Python generiert.
    Geändert von rucivfan (19. Mai 2014 um 09:23 Uhr)

  15. #1515
    Registrierter Benutzer Avatar von Monaldinio
    Registriert seit
    10.11.09
    Ort
    HRO
    Beiträge
    7.650
    Das ist doch schon mal ein Anfang rucivfan!
    Dann werde ich mich mal durch die Py Dateien kämpfen...

    Derweil habe ich wieder ein bischen Debuged

    1)

    Assert Failed

    File: CvGlobals.cpp
    Line: 1436
    Expression: eUnitNum > -1
    Message:


    Code:
    CvUnitInfo& CvGlobals::getUnitInfo(UnitTypes eUnitNum)
    {
    	FAssert(eUnitNum > -1);                                      <<<<<
    	FAssert(eUnitNum < GC.getNumUnitInfos());
    	return *(m_paUnitInfo[eUnitNum]);
    }

    Und dann noch...

    2)


    Assert Failed

    File: CvGlobals.cpp
    Line: 3645
    Expression: strcmp(szType, "NONE")==0 || strcmp(szType, "")==0
    Message: info type BONUS_HORSE not found, Current XML file is: xml\GameInfo/CIV4EspionageMissionInfo.xml



    Pferde?!?! ICh erinnere mich das du, rucivfan, mich schon darauf hingewiesen hast...aber wo soll ich da gucken?!?! XML?!? Python?!?!


    Edit: Bei Post #1509 gehe ich mal davon aus, das es von mir so richtig berichtigt worden ist (der Grün hinzugefügte Codeteil)
    Geändert von Monaldinio (19. Mai 2014 um 09:10 Uhr)
    Conflict on Chiron - Sid Meier's Alpha Centauri vs. Call to Power!

    Neu Version Conflict on Chiron v3.4 BETA - 16.01.16

    Patch1 - 07.04.16

    Die deutschen Sounds und Wunderfilme sind bereits in der MainFile integriert!
    Ihr könnt sofort loslegen.

    Über Feedback würde ich mich freuen...

Seite 101 von 180 ErsteErste ... 5191979899100101102103104105111151 ... LetzteLetzte

Berechtigungen

  • Neue Themen erstellen: Nein
  • Themen beantworten: Nein
  • Anhänge hochladen: Nein
  • Beiträge bearbeiten: Nein
  •