(SE4) Events that don't work

Author: Tobias
Date: Apr 22, 2019 11:38 AM
Category: Spaceport
Posts: 5
Has anybody ever gotten any random events (in ...Data/Events.txt) of the following types to work?

"Planet - Created"
"Points - Change"
"Warp Point - Opened"

I'm trying to find out if I simply made a syntax error that prevents the game from referencing the event or if they plain don't work.

Here are some of the events I've written that never appear (I tested it by making them the only events in the file and setting the event chance to 100 percent):

Type := Planet - Created
Severity := Low
Effect Amount := 0
Message To := System
Num Messages := 1
Message Title 1 := Event: New Planet detected
Message 1 := Heureka! The gravimetric survey revealed the recent formation of a previously unknown planet in [%SystemName].
Picture := Event044
Time Till Completion := 1
Num Start Messages := 1
Start Message Title 1 := Event: Gravimetric Survey
Start Message 1 := Scientists have commenced a gravimetric mapping project on an unusually dense asteroid belt at [%SectorName] in [%SystemName].

Type := Points - Change
Severity := Low
Effect Amount := 20000
Message To := Owner
Num Messages := 1
Message Title 1 := Event: A-Net Markets bullish
Message 1 := The Ansibles are humming with all of the positive stock market news. This is good news for our empire as well - taxes have increased our resource stocks by [%ActualAmount]M/O/R.
Picture := Event071
Time Till Completion := 0
Num Start Messages := 0

Type := Points - Change
Severity := Medium
Effect Amount := -25000
Message To := Owner
Num Messages := 1
Message Title 1 := Event: Heist
Message 1 := A notorious band - eleven pirates from eleven different species, led by Fazrah - staged a daring heist on one of our planets, stealing [%ActualAmount]M/O/R in hard cash.
Picture := Event040
Time Till Completion := 0
Num Start Messages := 0


Commenter: Fyron
Date: Apr 22, 2019 11:39 PM
(SE4) Events that don't work
Do you have any extra blank lines anywhere? IIRC, a double blank line after "BEGIN" in any file is typically treated as End of File by SE4's parser.

It's possible that the event chance settings are in decimals, rather than whole numbers. Try setting it to 1000?

If you start from the stock Events.txt file and delete everything except for the Score - Change event, for example, can you get that one to work?

Dunno if "Planet - Created" actually works, but its possible the game is creating them in systems you can't see. Try creating a single system map in the map editor.
Commenter: Tobias
Date: Apr 23, 2019 11:27 AM
(SE4) Events that don't work
Thank you for those suggestions. I could not solve the problem (and I'm fairly certain at this point it is indeed a question of those events simply not being implemented properly) but you helped me exclude more possible error sources:

- I checked the possible double line error by putting an event into the file after the problematic ones, and that occurred normally.

- I also started a test game with a fully settled 2-system quadrant (1 seemed to crash my SE4 for some reason) and the event chance set to 100, with an events.txt file composed only of events that I know to work. An event happened (almost) every turn, so the event chance in settings.txt does indeed appear to be a percentage.

- Something interesting I noted when combining these methods. I made an events.txt file with 15 copies of the stock "space rust" event (which is of the problematic "Points - Change" variety) and one event of a type I know to work (a level 1 plague), setting the event chance to 100. The "Points - Change" events never occurred, but the plague did.
Now the interesting part is that it did not occur every turn (as it would if it was the only event with a 100% chance), but only as often as it would if the other, non-functional events did occur, so roughly every 16 turns. I got the same result with a different event (a riot), so it was not an inherent limitation of the plage type event or anything.

So what I conclude is that (sorry if this sounds amateurish, I am a programming layman) the game calls for the "Points - Change" events normally as a random event, but neither the effects nor the event message trigger.

It's a bit of a letdown because I'll have to rewrite ~20 events in my actual mod and because this reduces my ability to include events with actual positive effects, but at least I managed to exclude other error sources. Thanks again.

P.S.: I also tried changing the event message target (from "Owner" to "All" or "System" and to check - by keeping close watch on the actual resources if the events actually occurred, but the message somehow didn't appear. That turned out not to be the case either.

P.P.S.: I tested this all with a completely clean install of SE4 Deluxe (hooray for GOG.com!) with the only files changed being events.txt and settings.txt
Commenter: Tobias
Date: Apr 24, 2019 4:38 AM
(SE4) Events that don't work
I did some more testing and it appears that "Research - Delete Project" and "Intel - Delete Project" don't work either as random events.

I guess a lot of things were just copy-pasted to "events" from "intel projects" without being implemented. (Which makes me wonder if planet creation and opening warp points would actually work as intel projects...)

P.S.: And the answer is there - no, they don't.
Edited 1 time(s). Lasted edited Apr 24, 2019 4:48 AM.
Commenter: NeuroCPU
Date: May 24, 2019 1:46 PM
(SE4) Events that don't work
can you prepare stock/tdm+fqm savegame to test that?