Losing fight with the editor

Moderator: AlvaroSousa

User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

Losing fight with the editor

Post by Uxbridge »

Messing with the editor can sometimes be very frustrating. Mostly, after a while, I figure out how to do things, but certain issues stubbornly resist clarification.

1. Is there, for instance, any way that one can see the value set in a resource while still in the editor? As it is now, I can find no other option but saving and starting the scenario in normal play mode. Very time-consuming.

2. How do you set the values you like to have in the resource? Presently, I clear the hex, enters the values in the window below, and then add the resource. Sometimes (when I have a look at the scenario in play mode) it works, sometimes not. Seems my method isn't the right one.

3. How does the Defence setting in a resource work? I want the resource to double the strength of units in it, and therefore set the value at 200%. When I open the scenario in game mode, however, it shows some odd value (like -4,1), that doesn't make any sense.
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

On the far right is a toggle that says Hotkeys. There is also a mods manual.

#1 Not hovering the map.
But you can see it here.
Resource -> left click resource on left -> look at bottom that lists the attributes.

OR

Resource -> right click any map hex that will show the current resource on the bottom of the screen.

#2 Resources -> left click the resource -> modify values at bottom of screen

#3 WarPlan reduces the attacker strength with defenses. Here is an example. You are attacking a fortress in the mountain with a level 2 entrench unit across a river.
Being an attacker 40%
Mountain 50%
River 50%
Fortress 50%
Entrenchment 10% each = 80% (100% - 10% - 10%)

Attacker attack strength is modified as such .4 x .5 x .5 x .5 x .8 = .04 = 4% effective strength on this suicide mission.
Makes sense?

You can ask me anything on the editor.
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

All right, I'll get it now. I was under the impression that one could alter the setting of each hex, but if I (ostensibly) do that, the values of that type of resource is changed all over the map. No wonder I couldn't get it to work.

Regarding fortress, if I want the attacker to be halved, I should set the resource to 50%, right?

Another thing – what will happen if I lower the defence value of a unit type, and then let two of these attack each other in turn. Will the change cancel out, so there's no difference from normal? Or would the attacking unit be stronger in the "die roll" even if both have the same characteristics? I want to give the units more punch and less armour plates.
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

yes 50%

Defense values are the chance real damage gets converted to effectiveness loss. High value greater chance. Everything is a minor adjustment that you change.
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

I see. Thought it was a counter value to the firearms/guns/artillery/tanks values. So what, in reality, does a "6" mean? Is it 6 % chance for conversion, or 60 %?

Is there anyway I can change the unit values to make them more equal in battle? That a one to one combat produces roughly the same effect on both units?
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

That is a complicated formula I would have to work out and test.

All the factors in the game are to allow different units to have different functions in a way that isn't game breaking over a few battles but the strategic decisions are seen over time.

Basically defense is this

defense(with tech) * experience% * .1f; } } = chance from 0 to 1 to block damage.
Then there is a 40% chance of damage to convert to eff loss and 60% chance for damage to be applied to strength without eff loss.

The entire combat process is very complex to the point even I have trouble remember what I did and have to look it up. There is lots of code under the game to make it as close to realistic as possible. More than 100 formula calculations for different things I'd say.

Best bet is to adjust but not replace. Otherwise you will be testing for a year yourself. WP is a WW2 engine not really meant for other times.


Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

All right. I'll leave this question for this scenario. If there's no way of getting units of equal strength battle with equal results, I have to rely on other methods to neutralize the need to have higher odds to get favourable results.

I have one issue not dealt with as yet, and that's the question of supply in the other thread.
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

There is always a 40% attack penalty.

Ok so I thought this out. When I made WP I added extra unused variables to the main data file just in case there were things that needed to be added after production. The reason is on how data is saved for a game like this. It is serialized and you can't undo or remove data. Then there is conflicting versions and how the code is written.

What I can do is add a new variable to the Campaign section in the editor that allows the attack penalty to be modified by the user. Right now it is hard coded.

I will put this in the next beta but it will be 2 official updates away. Why because the next update is in a few days and they already have the files. I can't change them. I also need some time to change the coding and verify nothing interferes.

You showed me that this small change can lead to other types of games being made on the engine.

Makes sense?

So the next beta I will add the user adjusted modifier for attacking. Then you can match up units equally and set the penalty to 0%.
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
ericdauriac
Posts: 99
Joined: Wed Sep 14, 2016 7:53 am
Location: Limoges

RE: Losing fight with the editor

Post by ericdauriac »

Hello,

Defense values are the chance real damage gets converted to effectiveness loss. But how the real damage sustained by a unit is calculate?
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

Sound terrific! [&o]

As for if it makes sense – yes, if it means what i hope it means.

What I want is that two units of the exact same type and set-up should produce the same combat results if met 1-1. If an Austrian landwehr brigade is attacking a French national guard brigade with an exact match in number and quality, the combat outcome should be expected to be fairly the same, save for the randomness of the "die roll" and the chance that the defender retreat. If a French guard unit attacks the Austrian landwehr, it would probably send it routing regardless of not having a 2-1 or 3-1 odds favour on the combat results table.

If the addition in the editor you're about to do, can still be offset by odds on the CRT, it would be good if the setting we will be free to change, not only takes the attackers penalty away. Make it possible to do the attacker stronger than the defender (if mechanics allow for that). This way one can tweak the effect of the CRT.

Hope that made sense. [:)]
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

ORIGINAL: Uxbridge

Sound terrific! [&o]

As for if it makes sense – yes, if it means what i hope it means.

What I want is that two units of the exact same type and set-up should produce the same combat results if met 1-1. If an Austrian landwehr brigade is attacking a French national guard brigade with an exact match in number and quality, the combat outcome should be expected to be fairly the same, save for the randomness of the "die roll" and the chance that the defender retreat. If a French guard unit attacks the Austrian landwehr, it would probably send it routing regardless of not having a 2-1 or 3-1 odds favour on the combat results table.

If the addition in the editor you're about to do, can still be offset by odds on the CRT, it would be good if the setting we will be free to change, not only takes the attackers penalty away. Make it possible to do the attacker stronger than the defender (if mechanics allow for that). This way one can tweak the effect of the CRT.

Hope that made sense. [:)]

There is no CRT to WP. It's all formula that simulates one based on a lot of variables.

If I think I know what you are asking then yes if 2 equal units attack 1 equal unit from 2 hexes that is 2:1 with no penalties except terrain/resource how ever you want to make it.
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

In that case it would be good if the setting we are able to change in the future could also make the attacker twice as strong, not only take away the penalty. Is that possible?
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

But they are twice as strong when 2 attack 1 if all things are equal
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

Well, I suppose that's better than how things are now, so the change is most welcome.

What I was looking for was an 1-1 relation between BOTH unit and combat. Assume there are two armies in Spain, one is the British under Wellington, the other the French under Marmont, both mowing to get into a favourable position to attack. Due to the scale these are made up of only one strong combat unit on each side. As it is now, attacking would almost always be at a disadvantage, since you need at least two units to achieve an equal chance of victory. This works well in an WWII setting, since there are a lot of units stretched out in a frontline. But it's difficult to simulate anything before WWI.

Anyway, removing the attacker penalty will go a good way closer to recreating other periods of warfare, especially if the scale of map is made more detailed. Eagerly looking forward to it. [:)]

User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

Alvaro, I have been off the game for some weeks, now have the latest official patch and the latest beta.

How about this:

What I can do is add a new variable to the Campaign section in the editor that allows the attack penalty to be modified by the user. Right now it is hard coded. I will put this in the next beta but it will be 2 official updates away. Why because the next update is in a few days and they already have the files. I can't change them. I also need some time to change the coding and verify nothing interferes.

From what you said earlier, you were going to check its feasability and put it in an upcoming beta. I can't see this in the current beta, and didn't expect it that early either, but since we're now in a convenient gaming pause with 1815, I will wait for the change before we start anew. What is the present ETA for it?

User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

It's going to be added to the beta. Currently I am waiting for the 1.00.081 update. Due to the Unity engine update change some players had graphical issues when in exclusive full screen that weren't there before in the 2017 engine. So I had to write an entire section to set the graphics in game.

After that I will address the issue in WPE.

It already has it in WPP.
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
User avatar
Uxbridge
Posts: 1513
Joined: Sun Feb 08, 2004 6:16 pm
Location: Uppsala, Sweden

RE: Losing fight with the editor

Post by Uxbridge »

Yeah, I saw the graphics issue. Must be very annoying when things like that pops up.

Thanks for the quick reply and change to the editor. It's highly valued. I will put the scenario on hold in wait for the beta.

Also, thanks for the hotkeys to trucks, attack/defend and upgrade. Those have been on my personal wish list for very long, but I never dared to add them to my official request list for fear of overburden you. The speed-up of micromanagement will be dramatic. [:)]
User avatar
magic87966
Posts: 152
Joined: Sat Mar 21, 2015 9:45 pm
Location: Winston-Salem, NC

RE: Losing fight with the editor

Post by magic87966 »

I know nothing about coding and the editor but I'm trying to keep up with your conversation just to learn. I have a question about the formula used to calculate attack odds. Al, you said "There is always a 40% attack penalty." To understand this I loaded an attack scenario with a German infantry attacking a Polish infantry on a 1.0 hex. Neither side had air or General support and there was no entrenchment. This is what I saw before the attack of a 10 offensive value vs. a 3 defensive value:

Image
Attachments
31.jpg
31.jpg (20.91 KiB) Viewed 614 times
"Gentlemen, when the enemy is committed to a mistake we must not interrupt him too soon."

Horatio Nelson
User avatar
magic87966
Posts: 152
Joined: Sat Mar 21, 2015 9:45 pm
Location: Winston-Salem, NC

RE: Losing fight with the editor

Post by magic87966 »

And here is the combat result:
How does the 10 attack factor get to a 4-1 if it's attacking as a 6 (40% attacker penalty)? Again - not a criticism, I'm just trying to follow along. Thanks!

Image
Attachments
results.jpg
results.jpg (27.67 KiB) Viewed 614 times
"Gentlemen, when the enemy is committed to a mistake we must not interrupt him too soon."

Horatio Nelson
User avatar
AlvaroSousa
Posts: 11628
Joined: Mon Jul 29, 2013 7:13 pm
Contact:

RE: Losing fight with the editor

Post by AlvaroSousa »

Because the numbers are estimate strengths not actual ones for the non-phasing player.
Your units are rounded down.
The odds are also estimated.
Then there is the luck roll too.
Creator Kraken Studios
- WarPlan
- WarPlan Pacific

Designer Strategic Command
- Brute Force (mod) SC2
- Assault on Communism SC2
- Assault on Democracy SC2
- Map Image Importer SC3
Post Reply

Return to “MODS and Scenarios”