They Are Billions

They Are Billions

Custom Levels for They Are Billions
Add custom levels to They Are Billions by subscribing to these workshop items!
了解更多
Icthulu 5 2018 年 11 月 22 日 下午 6:32
Game Won trigger help
I am trying to set a game won condition when the player captures a message box. I have tried tying it to a game won option in a repeating event based on a conditional flag, but it is not working.

Can someone help direct me to how I can get this to work in any way? For this map, I didn't want to have the player clear the map, but simply escape the area.
< >
正在显示第 1 - 9 条,共 9 条留言
CanuckBear 1 2018 年 11 月 22 日 下午 8:46 
Maybe put a unit generator generate a single unit at the beginning of the game, set the flag "game won" when the "wave is killed", surround the generator with steel fence, so it cannot escape. The player can shoot the unit when reaching the area. The problem is it might play the final wave theme.
最后由 CanuckBear 编辑于; 2018 年 11 月 22 日 下午 8:51
Icthulu 5 2018 年 11 月 22 日 下午 11:17 
Thanks, I was hoping to use that as a last resort. The goal was an honest win scenario, when that wasn't functioning, I tried spawnign a zombie in water to insta kill them. Which didn't work either.

Hopefully this is me not filling in the code fields properly or a bug, but if not, i think that your recommendation is a guaranteed method. Thank you.
Icthulu 5 2018 年 11 月 23 日 下午 8:14 
Sadly, I tried using the last swarm spawn tactic, and that doesn't work. The swarm dies and the game continues on unabated. Not sure why I can't end the game successfully.
CanuckBear 1 2018 年 11 月 23 日 下午 8:51 
I assume you had the flag "Game won if swarm destroyed" to Yes. I noticed sometimes these events are ignored if the event is setup to take place very early in the game (day00). Can you trigger the event on day02?
Edit: I'm testing it and that flag does nothing, the game carries on.
最后由 CanuckBear 编辑于; 2018 年 11 月 23 日 下午 9:04
CanuckBear 1 2018 年 11 月 23 日 下午 9:59 
Ok, I did more testing, still no success.

I have tried the Script of an event. There is a function "IsDead(id)". I created a Zombie (entity), surrounded it with steel walls, gave it the id "EndGameZombie". In the script, I added the action "Execute Code". For the Condition, I typed IsDead(EndGameZombie). For the Execute property I typed EndGameWon(). Nothing happens in the game. I kill the zombie, game carries on.

Maybe you can play more with the scripts.
Numantian Games  [开发者] 1 2018 年 11 月 23 日 下午 11:48 
Hi!

That should work fine. You can just set in the event the Game Won check and no need to set more actions with code.

Make sure that in the start time for the event is zero, otherwise the event won't evaluate the condition until their start time has been reached.

We have modified the editor so that the event start time is by default (0) instead of (1 day) as it can lead to confusion when dealing with script conditions.
Icthulu 5 2018 年 11 月 24 日 上午 9:31 
Sadly I'm not having any luck with getting this functioning. Maybe you can help me understand what I have miscoded.

I have a variable in variables and functions called wincon with initial value of 0

I have a UnitMapEventMessage 5x5 that has text and in the advanced options Execute box 'wincon=1;' (no quotes)

I have an event ID game won with condition wincon=1
repeat period 1h (tried leaving this blank and has same effect of not firing)
max repetitions 0 (left this alone, have tried 999, but that fails as well)
Game Won? checked Yes

Will add link to the game on workshop in a moment.

https://steamcommunity.com/sharedfiles/filedetails/?id=1573244755
最后由 Icthulu 编辑于; 2018 年 11 月 24 日 上午 9:32
Numantian Games  [开发者] 1 2018 年 11 月 24 日 上午 10:39 
Hi!
You are right, it was a really weird bug with the operator comparison equal.
It is fixed and tested it in your level. Just restart Steam to force the game update.
Thanks for the feedback.

About triggering events you don't need to set repetitions. The event is continuously evaluating the StartTime and the condition (if any), until both are true and then it triggers. And If it has repetitions the event will trigger when the time is reached and the condition is true again.

By the way, don't put buildings outside the buildable area of the map as it can cause weird problems.
Icthulu 5 2018 年 11 月 24 日 下午 2:38 
You are fantastic! Thank you!!!!!! I wish that every game I purchased had developers like you and that this game is a financial success. For me, it really checked every box.
< >
正在显示第 1 - 9 条,共 9 条留言
每页显示数: 1530 50

发帖日期: 2018 年 11 月 22 日 下午 6:32
回复数: 9