|
Thread: Detect if player has no towns | |
|
vulcancolak
Famous Hero
|
posted August 17, 2021 12:25 PM |
|
|
Detect if player has no towns
Hello everyone. Is there a good method to do that? I found the way to detect that but it looks painful. Negate and Minus variables when everytime specific players captures or loses towns.
We want to make specific players to defeat if they don't have any towns for x days OR instantly.
At least i was tried to find Player Owns Certain town is True of False. Because i was planning to do something like this.
Everytime it runs and checks player owns town named 1 false, town 2 false bla bla if all of these false, that means defeat the player.
I am not talking about the standart victory condition when you get all towns your enemy must get any town within 3 days. We are playing with 6 players, capturing towns of AI and dear idiot AI roaming the map with few units and we are trying to find and defeat him.
___________________________________________
Edit: I found a solution but it is instant.
Here is the event if you need.
1-) Simply give name all of the towns.
2-) Make it run every day separately for every player
3-) Conditional action.
If the red player owns town named 1
OR
If the red player owns town named 2
OR
If the red player owns town named 3
Then - Do Nothing
Else - Defeat
You have to add every town in here. Event is checking for "OR" that means if the player doesn't own any of these towns = defeat
Alternatively you can make it run weekly.
Edit 2: Just realized, we can make it work for current player. No need to make it for specific players.
Edit 3: What? Action > Lose and game says it is defeated but still it's hero and army exists into the map? And still he is able to play for few steps when it's first turn
___________________________________________
But still i am looking for making it for specific days. When player doesn't have any of the towns, countdown starts.
|
|
NimoStar
Responsible
Legendary Hero
Modding the Unmoddable
|
posted August 29, 2021 06:45 AM |
|
|
Countdown needs to be separate events like giving a message and "you only have 3 days", etc. Each day has to be another event that triggers the next one (via activating a variable)
Conquering a town should reset the variables.
____________
|
|
vulcancolak
Famous Hero
|
posted September 03, 2021 10:17 AM |
|
|
But i don't know how to do that.
|
|
NimoStar
Responsible
Legendary Hero
Modding the Unmoddable
|
posted September 04, 2021 06:28 AM |
|
|
You need like three variables for players and set it to true or false.
Like
Set true->Day 1 purple no towns
Set true->Day 2 purple no towns
Set true->Day 3 purple no towns -> Lose
And triggered events on player conquering town, that check for each possible player and set all those to FALSE
Kinda work.
____________
|
|
vulcancolak
Famous Hero
|
posted September 13, 2021 08:32 AM |
|
|
Can you show me how to do that? Because in this game i don't understand how the variables works.
|
|
Red_White
Disgraceful
Tavern Dweller
|
posted September 30, 2021 05:53 PM |
- penalty applied by Galaad on 25 Feb 2022. |
|
NimoStar said: You need like three variables for players and set it to true or false.
Like
Set true->Day 1 purple no towns
Set true->Day 2 purple no towns
Set true->Day 3 purple no towns -> Lose
And triggered events on player conquering town, that check for each possible player and set all those to FALSE
Kinda work.
This is standard condition of winning in H4.
|
|
NimoStar
Responsible
Legendary Hero
Modding the Unmoddable
|
posted September 30, 2021 06:57 PM |
|
|
Don't blame me, that's what Vulcan asked for :v
____________
|
|
vulcancolak
Famous Hero
|
posted October 08, 2021 01:57 PM |
|
|
Red_White said:
NimoStar said: You need like three variables for players and set it to true or false.
Like
Set true->Day 1 purple no towns
Set true->Day 2 purple no towns
Set true->Day 3 purple no towns -> Lose
And triggered events on player conquering town, that check for each possible player and set all those to FALSE
Kinda work.
This is standard condition of winning in H4.
So why computer can roam around the map for 30+ days without no towns? Still i don't know how to make it.
|
|
|