towatai

[SOLVED] Completely random Loot possible?

16 posts in this topic

is it possible to let spawn loot completely randomized at the buildings? it would be nice if some buildings have loot, others not and that fully randomised. it´s a little bit boring finding loot in every type of building.

Share this post


Link to post
Share on other sites
3 hours ago, towatai said:

is it possible to let spawn loot completely randomized at the buildings? it would be nice if some buildings have loot, others not and that fully randomised. it´s a little bit boring finding loot in every type of building.

That's how the system works by default. If you have loot in every building, you need to reconfigure your loot settings.

  • Like 1

Share this post


Link to post
Share on other sites
Advertisement

i´ve played around the last days with the default exile l.ootsettings... Coverage etc. and its not completely what i want. it would be nice if random buildings would get NO loot and others the normal amount.. so finding loot or good loot would become a gambling game for the players... over and over again...

Share this post


Link to post
Share on other sites

i dont want to edit my loottable... it should be possible that loot spawns in every type of building! it should be random, for all buildingtypes, that loot DONT spawns inside them for the player. if i delete a buildingclass from my table it is forever! if i change the lootcoverage there is a minimum of one lootspot per building and so on...

Share this post


Link to post
Share on other sites
56 minutes ago, towatai said:

i´ve played around the last days with the default exile l.ootsettings... Coverage etc. and its not completely what i want. it would be nice if random buildings would get NO loot and others the normal amount.. so finding loot or good loot would become a gambling game for the players... over and over again...

That is how it works.

  • Like 1

Share this post


Link to post
Share on other sites

Correct me if I'm wrong but if you have 10 loot spawns in a building with 60% coverage set, there will ALWAYS be 6 random loot spawns populated in that building. Exile got around the excess loot or the ability to reduce chance of good items through the use of rubbish however.

@kuplion does that sound right?  Certainly on my last 2 servers this is how it has worked reliably. 

@towatai correct me if I'm wrong, what you are asking for is a way to have it a bit more random with an additional chance for a building to spawn ANY loot and not always have the % coverage just with random rubbish in the mix.

Share this post


Link to post
Share on other sites
14 hours ago, towatai said:

i dont want to edit my loottable... it should be possible that loot spawns in every type of building! it should be random, for all buildingtypes, that loot DONT spawns inside them for the player. if i delete a buildingclass from my table it is forever! if i change the lootcoverage there is a minimum of one lootspot per building and so on...

I was doing some research into what you're asking. I haven't tested this, but it might be a step closer.

There is a "select" function as shown in the Bohemia Wiki - Select

This function could possibly be used in the exileclient_system_lootmanager_thread_spawn.sqf to select a set number of buildings to spawn loot in. At the bottom of the file, you could modify it like so...

if ((count _buildingNetIdsToSpawnLootIn) > 0) then 
{
    _selectedBuildings = _buildingNetIdsToSpawnLootIn select [0,3];
    ["spawnLootRequest", [_selectedBuildings]] call ExileClient_system_network_send;
};

In theory, this line of code will pick the first 3 buildings from the _buildingNetIdsToSpawnLootIn array to spawn loot in. If there are less than or only 3 buildings in the array, all those buildings will spawn loot.  However, if there are 10 buildings in the array, 7 of the buildings will not spawn loot. While not completely random in the selection of buildings from the array, I am assuming the order in which the buildings are added to the array of possible loot spawn locations is somewhat random.

Or, you might be able to do a percentage of the buildings using something similar to:

if ((count _buildingNetIdsToSpawnLootIn) > 0) then 
{
	_buildingPercent = 50;
	_buildingCount = floor ((count _buildingNetIdsToSpawnLootIn) * _buildingPercent / 100);
	_selectedBuildings = _buildingNetIdsToSpawnLootIn select [0,_buildingCount];
	["spawnLootRequest", [_selectedBuildings]] call ExileClient_system_network_send;
};

Again, this is untested and the syntax may not be proper. This was just a quick idea on how you might be able to accomplish the randomness you are looking for.

Edited by Kurewe
  • Like 2

Share this post


Link to post
Share on other sites
5 minutes ago, towatai said:

oh thanks! i will test it and give some feedback :D

I just edited my post because I thought about using a percentage instead of a strict number. Take a look at my post again for that code. Also, don't forget to add the extra variable(s) I mentioned to the "private" line at the top of the file.

  • Like 1

Share this post


Link to post
Share on other sites
Advertisement
Guest
This topic is now closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.