Modding - Setting Artefacts spawn chance

Arszi
Scavenger
Posts: 36
Joined: 04 Jan 2018, 06:45

Modding - Setting Artefacts spawn chance

Postby Arszi » 01 Feb 2018, 18:14

I'd like to tweak the artefact spawn system.
I want to decrease the the artefact spawn chance for the heavily populated maps (for example Cordon, Garbage, Swamp), and increase the chance for the remote ones (Zaton, Red Forest, Outskirts, Power plant).

How could I tweak the spawn chance, if I want, for example, that the anomaly should have 10-20% chance to spawn an artefacts? (Tiers do not count)

esc_smart_terrain_8_9_anomal_zone.ltx

[anomal_zone]

respawn_tries = 1
max_artefacts = 1
artefacts = af_medusa, af_cristall_flower, af_ameba_slime, af_night_star, af_ameba_slug, af_vyvert, af_gravi, af_gold_fish, af_ameba_mica
start_artefact = ; af_ameba_slime
coeff = 3, 3, 3, 3, 2, 2, 2, 1, 1
artefact_ways = esc_anomal_way_2
field_name = esc_zone_field_radioactive_weak_0002

User avatar
Balathruin
Trespasser
Posts: 65
Joined: 18 May 2017, 13:36

Re: Modding - Setting Artefacts spawn chance

Postby Balathruin » 02 Feb 2018, 03:57

Arszi wrote:How could I tweak the spawn chance, if I want, for example, that the anomaly should have 10-20% chance to spawn an artefacts? (Tiers do not count)

You might be able to do this by changing how the script works. Without that, I'd go for a 5 or 10% respawn and increase the tries.

Arszi
Scavenger
Posts: 36
Joined: 04 Jan 2018, 06:45

Re: Modding - Setting Artefacts spawn chance

Postby Arszi » 02 Feb 2018, 15:10

Thank you Balathruin!

I found the script file which spawns the artefacts, so I can work with this even better, than with the meta file.

Could you please tell me the name of the function, which triggers (starts) the blowouts?

luppolo
Scavenger
Posts: 37
Joined: 04 Nov 2016, 21:58

Re: Modding - Setting Artefacts spawn chance

Postby luppolo » 02 Feb 2018, 19:19

Code: Select all

local sm = surge_manager.SurgeManager
sm:start(true)


it exists also as debug console command, "surge start" (which just runs the code above)

Arszi
Scavenger
Posts: 36
Joined: 04 Jan 2018, 06:45

Re: Modding - Setting Artefacts spawn chance

Postby Arszi » 04 Feb 2018, 08:11

Thank you! The script worked like a charm :)


Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest

cron