Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add reclaim information to `_scenario.lua #399

Open
Garanas opened this issue Jun 3, 2024 · 5 comments
Open

Add reclaim information to `_scenario.lua #399

Garanas opened this issue Jun 3, 2024 · 5 comments

Comments

@Garanas
Copy link
Member

Garanas commented Jun 3, 2024

The FAForever map editor adds a table to the scenario file that represents the amount of reclaim on the map. The entire scenario file is included in the replay, see also:

I'd like to show this information in the detailed replay viewer, but generated maps do not populate the field in the scenario file. It would be nice if it did 😃 !

version = 3 -- Lua Version. Dont touch this
ScenarioInfo = {
    name = "Lost Lands",
    description = "20 km x 20 km 4v4 - Made By Penguin",
    preview = '',
    map_version = 5,
    type = 'skirmish',
    starts = true,
    size = {1024, 1024},
    reclaim = {24980.59, 58608},        -- <-- this particular field, which is {mass, energy}
    map = '/maps/lost_lands.v0005/Lost_Lands.scmap',
    save = '/maps/lost_lands.v0005/Lost_Lands_save.lua',
    script = '/maps/lost_lands.v0005/Lost_Lands_script.lua',
    norushradius = 50,
    Configurations = {
        ['standard'] = {
            teams = {
                {
                    name = 'FFA',
                    armies = {'ARMY_1', 'ARMY_2', 'ARMY_3', 'ARMY_4', 'ARMY_5', 'ARMY_6', 'ARMY_7', 'ARMY_8'}
                },
            },
            customprops = {
                ['ExtraArmies'] = STRING( 'ARMY_17 NEUTRAL_CIVILIAN' ),
            },
        },
    },
}
@Garanas
Copy link
Member Author

Garanas commented Jun 3, 2024

Counting the props is do-able, but is the generator able to retrieve the reclaim value from the blueprint files?

@lL1l1
Copy link

lL1l1 commented Jun 21, 2024

With the recent map generator updates on the client, it's become possible to randomly use the high reclaim prop generators (Boulder field and High Reclaim), which causes people to abandon custom games often because they don't like playing with very high reclaim. Adding this field would give the lobby a chance to tell players how much mass is on the map, but it would also be nice to show the reclaim in the client by putting the amount of reclaim in the map description (easier solution than updating client to show the reclaim values).

@BlackYps
Copy link
Collaborator

The used generators are in the map description. Do people not know that Boulder field and High Reclaim produce a lot of reclaim? If they do know, they apparantly don't look at the map description, so adding it there won't improve things.

@lL1l1
Copy link

lL1l1 commented Jun 21, 2024

Considering that the prop generators were relatively hidden until now, boulder field is brand new, and that the high reclaim options became much more common since they're not constrained by terrain sliders anymore, I think adding an easily understandable reclaim value in the description is still valuable.

Another idea is to just give users the ability to choose which prop generators can be randomly chosen by using a checkbox in the dropdown list of options.

@BlackYps
Copy link
Collaborator

yeah, I can see the value in showing the reclaim total in the description. Thinking about it more, it's probably quite complicated to pull of, because the map generator doesn't know the reclaim values of any of the props. I'm not sure what a good way to solve this would be.

Making prop generators multi-selectable is not supported at the moment. The generator only takes one specific prop generator as input. We could maybe fake it in the same way as the matchmaker faction selection works i.e. this logic only exists in the client and the client chooses one of the selected prop generators at random once you hit the generate button and then the client calls the map generator with the specific prop generator passed to it.

What we could do as a general improvement is to have an explanation text what each generator option does roughly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants