[Darkest Hour Modding] Modding Fragen

Moddingecke Submods für Darkest Hour

Moderator: Moderatoren

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 9. März 2015 09:59

Danke, das funktioniert. Analog dazu müssten dann ja auch navy bzw. air funktionieren, tun es aber nicht.

Benutzeravatar
Schwenn
Immunes
Immunes
Beiträge: 43
Registriert: 26. September 2013 14:01

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Schwenn » 11. März 2015 18:09

Ich glaube, die Befehle gibt es nicht.
"naval" könnte man nochmal ausprobieren, aber ich glaube auch dass so eine Zählung nicht sinnvoll ist. Dafür kann man die einzelnen Einheitentypen zählen lassen, dass sollte vorallem im MArine-Bereich eh besser sein.
(Aber auch hier glaube ich, dass Einheiten im Bau dazu gezählt werden. Zumindest jede Serie sollte bereits zu den bestehenden addiert sein, zumindest habe ich das Gefühl gehabt, dass es so ist beim testen meiner Bau-AIs für SW)

Benutzeravatar
DerStudti
Pilus Posterior
Pilus Posterior
Beiträge: 1355
Registriert: 21. August 2012 14:49

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon DerStudti » 11. März 2015 18:27

Code: Alles auswählen

navy = { size = X [type  = 0/1] [when = 0/1] [where = 0/1] [which = 0/1] [country = TAG] }
                     # check if TAG (or country in question when not specified or country = -1) has at least X ships
                     # type  = 0 (default) - count all ship types, type  = 1 - count all except TP, SS and SSN
                     # when = 0 (default) - count only ready ships, when = 1 - count ready + ships under construction
                     # where = 0 (default) - count foreign expeditionary forces too, where = 1 count own forces under own control only
                     # which = 0 (default) - slow, but accurate real-time check, which = 1 (recommended) fast check that uses daily updated stats only for own units, including sent as expeditionary forces to other countries
navy = X               # check if country in question has at least X ships of all types ready, including foreign expeditionary forces and excluding own units sent to other countries

air = { size = X [type  = 0/1] [when = 0/1] [where = 0/1]  [country = TAG] }
                     # check if TAG (or country in question when not specified or country = -1) has at least X airplanes
                     # type  = 0 (default) - count all airplanes types, type  = 1 - count all except TRA, Rockets and Flying bombs
                     # when = 0 (default) - count only ready airplanes, when = 1 - count ready + airplanes under construction
                     # where = 0 (default) - count foreign expeditionary forces too, where = 1 count own forces under own control only
                     # which = 0 (default) - slow, but accurate real-time check, which = 1 (recommended) fast check that uses daily updated stats only for own units, including sent as expeditionary forces to other countries
air = X                  # check if country in question has at least X airplanes of all types ready, including foreign expeditionary forces and excluding own units sent to other countries                                             

army = { size = X [type = 0/1] [when = 0/1] [where = 0/1] [which = 0/1] [country = TAG] }   
                     # check if TAG (or country in question when not specified or country = -1) has at least X land divisions
                     # type = 0 (default) - count all land unit types, type = 1 - count all except GAR and HQ
                     # when = 0 (default) - count only ready divisions, when = 1 - count ready + divisions under construction
                     # where = 0 (default) - count foreign expeditionary forces too, where = 1 count own forces under own control only
                     # which = 0 (default) - slow, but accurate real-time check, which = 1 (recommended) fast check that uses daily updated stats only for own units, including sent as expeditionary forces to other countries
army = X               # check if country in question has at least X land divisions of all types ready, including foreign expeditionary forces and excluding own units sent to other countries


siehe event commands.txt

:)


Zusätzliche Slots für Minister im Diplomatiemenü kann man IMHO nicht modden.

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 11. März 2015 21:46

Probiert habe ich jetzt navy, navy_size, navy_strength, naval, naval_size, naval_strength, aber nichts davon funktioniert. Ob kopiert oder mit Hand geschrieben, es geht nicht. :(

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 27. März 2015 14:41

Hallo

Ich habe ein Problem mit diesem event:

#####################
# De Gaulle's appeal
#####################
event = {
id = 2001003
random = no
country = ENG
style = 2
picture = "Appel_de_Gaulle"
decision_picture = "decision_appel_de_gaulle"

name = "4060name"
desc = "4060desc"

decision = {
event = { id = 2002008 days = 30 } #L'Etat Français
NOT = {
exists = U01
#region = { region = France country = -3 data = 2 value = 1 }
}
}
decision_trigger = {
event = { id = 2002008 days = 30 } #L'Etat Français
NOT = { exists = U01 }
}
trigger = {
event = { id = 2002008 days = 30 } #L'Etat Français
NOT = { exists = U01 }
}

date = { day = 1 month = january year = 1936 }
offset = 15
deathdate = { day = 30 month = december year = 1963 }

action = {
name = "4060a"
command = { type = relation which = FRA value = -100 }
command = { type = independence which = U01 value = 1 }
command = { type = alliance which = U01 }
command = { type = transport_pool which = U01 value = 50 }
#command = { type = make_puppet which = U01 }
#command = { type = trigger which = 2002009 }
}
}

Und zwar wird wird das Freie Frankreich nicht erschaffen. Ich habe es von Hand ausgelöst und es in ein eigenes event gepackt was aber auch nicht funktioniert.

Benutzeravatar
DerStudti
Pilus Posterior
Pilus Posterior
Beiträge: 1355
Registriert: 21. August 2012 14:49

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon DerStudti » 27. März 2015 17:23

Kontrolliert denn ENG die Provinzen, die für das freie Frankreich minimal nötig sind?

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 27. März 2015 19:24

FRA kontrolliert die afrikanischen Kolonien. Die Aufteilung dieser zwischen Vichy und Freiem FRA werden im nachfolgenden event geregelt.

Benutzeravatar
DerStudti
Pilus Posterior
Pilus Posterior
Beiträge: 1355
Registriert: 21. August 2012 14:49

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon DerStudti » 27. März 2015 20:05

Es kann nur die Nation eine andere freilassen, die auch deren minimum-Provinzen kontrolliert.

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 27. März 2015 20:25

Danke. Also brauche ich ein Brückenenvent wo Vichy das Freie FRA freilässt.

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 5. Mai 2015 15:29

Hallo

Im Moment zerschießt es mir immer die Saves. Immer wenn ich im Krieg bin. Es scheint irgendwie an den Event IDs zu liegen, aber mehr weiß ich nicht.

Bild

Danke schonmal.

Benutzeravatar
flogi
Tribunus Angusticlavius
Tribunus Angusticlavius
Beiträge: 3076
Registriert: 20. August 2012 20:19
:
Teilnahme an einem Contest Modder Gewinner Userwahl
Kontaktdaten:

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon flogi » 5. Mai 2015 22:49

Schwer zu sagen. Manchmal machen zu viele Zeichen in der desc="XX" Schwierigkeiten.
Sonst kann ich auf den ersten Blick da nichts erkennen. Aber das ganze Event sieht man ja auch nicht.

Benutzeravatar
DerStudti
Pilus Posterior
Pilus Posterior
Beiträge: 1355
Registriert: 21. August 2012 14:49

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon DerStudti » 5. Mai 2015 23:06

Generell ist es empfehlenswert, die Texte in CSV-Dateien auszulagern. Ob sie aber hier die Fehlerursache sind, kann eigentlich nur ein Blick ins Save an die beschriebene Stelle klären.

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 6. Mai 2015 11:31

Bei zu langen Berschreibungen gibt es ja auch eine Fehlermeldung darüber, ich kürze sie dann dementsprechend. Ich habe das gerne in einer Datei damit ich sofort den Überblick habe und nicht noch mehr suchen muss.

Edit: Ich habe gerade das save nach der entsprechenden ID durchsucht. Bei der vorangehenden ID stand ein Minszeichen - vor der ID. Als einziges in der gesamten Liste. Das habe ich mal entfernt und es scheint zu funktionieren.

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 8. Mai 2015 14:45

Ich habe jetzt herausgefunden das dass das event mit dem Vorzeichen jedes mal direkt vor demjenigen steht welches dann als Fehler ausgegeben wird. Anscheinend kommt das Spiel mit dem Vorzeichen nicht klar. Die ID ist -955967286. Das ist aber weder ein event von mir noch eins von DH. Wo kann es also herkommen und wie kann ich das in Zukunft ausschließen?

Benutzeravatar
Sarge
Tessaricus
Tessaricus
Beiträge: 372
Registriert: 1. September 2012 15:45

Re: [Darkest Hour Modding] Modding Fragen

Beitragvon Sarge » 8. Juli 2015 10:29

Hallo

Ich arbeite gerade an diesem Event:


#########################################################################
# Ende des Empires
#########################################################################
event = {
id = 66600017
tag = { ENG }
random = no
decision = {
atwar = no
control = { province = 29 data = ENG } #London
control = { province = 163 data = -3 } #Berlin
control = { province = 419 data = -3 } #Rome
control = { province = 1552 data = -3 } #Tokyo
NOT = { exists = GER }
NOT = { exists = ITA }
NOT = { exists = JAP }
year = 1947
}
decision_trigger = {
atwar = no
control = { province = 29 data = ENG } #London
control = { province = 163 data = -3 } #Berlin
control = { province = 419 data = -3 } #Rome
control = { province = 1552 data = -3 } #Tokyo
NOT = { exists = GER }
NOT = { exists = ITA }
NOT = { exists = JAP }
year = 1947
}
trigger = {
atwar = no
control = { province = 29 data = ENG } #London
control = { province = 163 data = -3 } #Berlin
control = { province = 419 data = -3 } #Rome
control = { province = 1552 data = -3 } #Tokyo
NOT = { exists = GER }
NOT = { exists = ITA }
NOT = { exists = JAP }
year = 1947
}
name = "Das Ende des Empires"
desc = "Obwohl England zu den Siegermächten des Zweiten Weltkriegs gehörte war dies ihm nur gelungen indem es

massiv auf Truppen aus den Ländern des Empires zurückgegriffen hatte. Kanada stellte die viertgrößte Armee der Alliierten

und Indien sowie Australien kämpften selbstständig gegen die Japaner im Pazifik. Dies führte dazu das diese Länder ein

großes eigenes Selbstbewusstsein entwickelte bei dem sie sich nicht länger bevormunden lassen würden. Eine Lösung musste

sehr schnell gefunden werden."
style = 2
picture = "decision_english_commonb"
decision_picture = "decision_english_common"

date = { day = 9 month = january year = 1942 } #27.04.49
offset = 1 # Check for trigger conditions every day
deathdate = { day = 30 month = december year = 1963 }

action_a = {
name = "Entlassen wir die Länder und errichten wir ein Commenwealth"
ai_chance = 95
#command = { type = independence which = AST }
#command = { type = alliance which = AST }
#command = { type = secedeprovince which = AST value = 1614 } #Christmas Island
#command = { type = secedeprovince which = AST value = 2592 } #Norfolk Island
#command = { type = independence which = CAN }
#command = { type = alliance which = CAN }
#command = { type = independence which = NZL }
#command = { type = alliance which = NZL }
#command = { type = independence which = SAF }
#command = { type = alliance which = SAF }
command = { type = inherit which = u02 value = 1 }
command = { type = independence which = IND value = 1 }
command = { type = alliance which = IND }
#command = { type = secedearea which = IND value = "Rajastan" when = 2 }
command = { type = secedeprovince which = u02 value = 1509 }
command = { type = secedeprovince which = u02 value = 1510 }
command = { type = secedeprovince which = u02 value = 1511 }
command = { type = independence which = PAK }
command = { type = alliance which = PAK }
#command = { type = secederegion which = PAK value = "Pakistan" when = 2 }
command = { type = secedeprovince which = PAK value = 1538 when = 0 } #Gwador
command = { type = secedeprovince which = PAK value = 1533 when = 0 } #Karachi
command = { type = secedeprovince which = PAK value = 1529 when = 0 } #Quetta
command = { type = secedeprovince which = PAK value = 1537 when = 0 } #Peshawar
command = { type = secedeprovince which = PAK value = 1530 when = 0 } #Lahore
command = { type = secedeprovince which = PAK value = 1534 when = 0 } #Rawalpindi
command = { type = secedeprovince which = PAK value = 1539 when = 0 } #Muzaffarabad
command = { type = independence which = BUR }
#command = { type = independence which = SOM }
#command = { type = alliance which = CAN }
#command = { type = independence which = IRQ }
##command = { type = alliance which = CAN }
#command = { type = independence which = MOZ }
##command = { type = alliance which = CAN }
#command = { type = independence which = ETH }
##command = { type = alliance which = ETH }
#command = { type = independence which = MLY }
#command = { type = alliance which = MLY }
#command = { type = independence which = RHO }
#command = { type = alliance which = RHO }
#command = { type = independence which = GAB }
#command = { type = alliance which = GAB }
#command = { type = independence which = GLD }
#command = { type = alliance which = GLD }
#command = { type = independence which = GUI }
#command = { type = alliance which = GUI }
#command = { type = independence which = GUY }
#command = { type = alliance which = GUY }
#command = { type = independence which = NIG }
#command = { type = alliance which = NIG }
#command = { type = independence which = SUD }
#command = { type = alliance which = SUD }
#command = { type = independence which = ANG }
#command = { type = alliance which = ANG }
}
action_b = {
name = "Brauchen wir nicht"
ai_chance = 5
command = { }
}
}

Alle independence/ alliance Einträge mit Raute erstmal nicht beachten, die funktionieren nämlich. Ich habe sie nur so gekennzeichnet um mich ganz auf das Indien Problem konzentrieren zu können.

Ziel ist das Empire durch das Commowealth zu ersetzen. Das klappt auch soweit ganz gut, bis auf die Umwandlung des Raj in Indien, Pakistan und Burma.

Lasse ich Indien ohne den inherit Befehl frei erhalten sie bloß Ceylon als Provinzen, mit inherit aber das ganze Land. Igendetwas ist auch bei dem ganzen secede Kram falsch. Weder secederegion oder -area funktioniert. Stattdessen erhalten sie mit den drei -province Einträgen ebenfalls das ganze Land.

PAK hingegen wird überhaupt nicht freigelassen obwohl ich ja über inherit über die nötigen Provinzen verfüge.

Ich denke ich bin gerade mal wieder sehenden Auges blind.