[dev request] New Event "remove tech" if possible

Have a feature request for SRU? Post here.

Moderators: Balthagor, Legend, Moderators

Post Reply
vahadar
Colonel
Posts: 257
Joined: May 19 2010
Human: Yes

[dev request] New Event "remove tech" if possible

Post by vahadar »

Hello,

I would like to use events to remove specific tech id from country, and i was wondering if it would be difficult to add this in SR.

Today we have event 22 that can add techs to a country.
We also have event 45 condition 21 that test if a country has a tech.

This event could normally be used to remove tech from a country.
Or it can be used to remove "variable" tech (modded tech) assigned to a country after some event.

If we have one event that remove tech from a country this would allow new possibilities to make infinite variables for modding that would stock some "information".

Could you guys at BattleGoat consider it ? :D
User avatar
Balthagor
Supreme Ruler
Posts: 22099
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Re: [dev request] New Event "remove tech" if possible

Post by Balthagor »

We'll consider it.
21633
Chris Latour
BattleGoat Studios
chris@battlegoat.com
vahadar
Colonel
Posts: 257
Joined: May 19 2010
Human: Yes

Re: [dev request] New Event "remove tech" if possible

Post by vahadar »

Thank you Balthagor for considering :)

Giving/removing custom non tradeable and non research techs through events would be like setting global variables or assigning temporary boost effect to a country, i'm eager to use that possibility ;)
vahadar
Colonel
Posts: 257
Joined: May 19 2010
Human: Yes

Re: [dev request] New Event "remove tech" if possible

Post by vahadar »

Balthagor wrote: Aug 29 2017 We'll consider it.
21633
@Balthagor i was wondering if this was implemented, i really hope i can use it someday to use techs as variables :) This would make the game much more powerfull in customisation through events, it would be a simple but very effective way to open almost endless possibilities for modders.

I might have a suggestion for the parameters to make it not too complicated :
Use event 22 and for i0 and i2, make it possible to use negative numbers here (like used for quite some other events to negate something), so we can specify a tech id or unit id we want to remove instead.

In my WIP SR1936/Ultimate - 1936 total modification mod i have an series of events for various countries like Germany that would need this badly to make scripting those events much more easier and flexible.

An exemple, i have wrote a complex chain of events to allow Germany to "colonize" quite some parts of Poland or Ukraine if some conditions are met for various predefined BZs.
Today if Germany has some specific BZ controlled (using condition test if has land in specific hex with BattleZone test), i fire an event that gives a tech (no trade) that adds to research queue.
When researched (to simulate efforts and spending made to colonize the area), i have another test that checks if Germany has this tech researched (regionnal tech test),
If true, i create in the "capital" of the BZ a unique unit, to simulate the administration of the BZ. This unit cant move and so on so its fixed. At the same time i switch the loyalty of the BZ from previous owner to Germany.
I monitor the state of this unit, and if the unit is destroyed (condition test regionnal hex test) this means the administration of the BZ is lost and i fire another event that switch back the loyalty of this BZ from the conqueror Germany, to previous owner like Poland or USSR.

I would love it to use tests on tech only, adding and removing them when needed.
This would be shorter if i was just making a test to check BZ ownership like before, then a test on the previous to allow a tech to be researched to simulate colonization of this specific BZ, when researched and using a regional hex test to check if still under Germany control to change loyalty ownership if BZ lost, then fire another event to remove the colonization tech, which would fire the event that would switch back loyalty to original owner. And this could start again and again depending on war tides.

Another exemple where i could greatly benefit from the ability to remove a tech :

I have made a whole new worldwide market for unit trading in my 1936mod. Of course you can trade units if you have a NAP or Alliance, but here the goal is to allow you to "order" some units from some specific major nations (predefined in events, like USA, Japan, Germany...).
I built it using non tradable and researchable techs to simulate access to an axis or allies unit shop. The way it is written allow you to research a tech "pro axis" or "pro allies" depending on your current sphere alignment (through tests). This leads to more techs "pro axis" or "pro allies" (mutually exclusive through tests on alignment, not gonna explain in details it is a bit more complicated than just a tech tree) to simulate efforts made by a government to lean closer to a specific sphere leader, in addition to current vanilla means.
Then when you have researched the finals techs (that also change your sphere status), you have access to a "unit shop", which is actually a tech tree consisting or various researchable techs for each year, exemple 1936-axis-air-unit-batchXX, 1936-axis-land-unit-batchXX, 1937-axis-air-unit-batchXX and so on. There is a test to check if you have the tech that gives access to each shop, and each year another test depending on this access to make the shoping possible for new unit to order (by researching them). Then you order a batch for exemple by researching 1936-axis-air-me109-batch4 (to have 4 me109 interceptor), all the shop techs are researched in one day but the cost match the unit cost times the number of unit in batch. then a test checks if you have this tech researched and the units are delivered in reserved after a fixed amount of days corresponding to the time it takes to build this type of unit.
Of course all the shoping units that you can possibly order in this axis/allies shop are all scripted in advance.

My problem is, what if the sphere score of your nation change? I would like to remove the tech to access the shop, by checking your sphere score through a recurrent test, the result of this test would prevent or not researching the various techs for units batch you can get. This would also allow you to search again this shop access if for any reason your sphere score changed during the course of the game.

It is just an exemple among dozens and dozens of ideas i have for this project.
User avatar
Balthagor
Supreme Ruler
Posts: 22099
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Re: [dev request] New Event "remove tech" if possible

Post by Balthagor »

It remains on the wishlist, and reasonably close to the top, but some other interesting things have kept it from next in line.
Chris Latour
BattleGoat Studios
chris@battlegoat.com
Post Reply

Return to “Suggestions - SRU”