Jump to content

How are arenas chosen?

Closed 1.0.12

OldRusty
OldRusty

Posted

I have bought your friends map pack for the plugin, I copied the maps into File Manager > /oxide/data/survivalArena/ and the plugin recognises the arenas and I can spawn each one manually, the arena files are named  Arena.json, DeathMatch.json, Military.json and Canyon.json.

When ever I play the game with players voting to start an arena I only ever get the Canyon map.

Does the plugin chose one at random? or is there a way to choose the map as an ordinary player?

imthenewguy

Posted

It should be picking a random arena.

 

        string GetRandomArena()
        {
            List<string> arenas = Pool.GetList<string>();
            arenas.AddRange(Arenas.Keys);
            var name = arenas.GetRandom();
            Pool.FreeList(ref arenas);
            return name;
        }

It uses .net's native GetRandom method to pick a random arena by name.

imthenewguy

Posted

If you type the /survivalarena command into chat, do all of the arenas appear?

imthenewguy

Posted

I tested on my server with the map pack, and I have no issues with it selecting random maps.

imthenewguy

Posted

Changed Status from Pending to Closed

1.4m

Downloads

Total number of downloads.

6.9k

Customers

Total customers served.

102.3k

Files Sold

Total number of files sold.

2m

Payments Processed

Total payments processed.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.