• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

Random Number Generator

Messages
1,061
Country
unitedstates
Here's a site that I often use to generate random numbers for scenery development.

http://www.random.org/integers/

For example I want to be able to place campfire scenery MDL's throughout large scenery areas and have the lat/lon information but I don't want to place all the objects facing true north on every one.

So I input how many numbers in my list I want to generate (from 1 to 10,000) and in terms of numbers "0" to "360". I want to copy and paste the list into an excel spreadsheet so I only want 1 column of data to be returned.

Click on "Get Numbers" and that's all there is to it. :)
 
In Excel you can just use =randbetween(0,360) and then paste the formula into as many rows as you need. Select the desired number of empty rows including the one containing the formula and press Ctrl+D, it will fill the entire selected column with random numbers. F9 refreshes the random number generation.

I also do this to randomize placements both for heading and scale, particularly on vegetation objects.

Jim
 
Last edited:
Just tried that formula on Excel 2002 and unfortunately it doesn't work on my version of excel :(

EDIT: however =RAND()*360 does work in Excel 2002
 
Last edited:
I'm actually using Excel 2002, RAND()*360 does work also but doesn't return a whole number (which may not be a problem, you could format cells to decimal places "0" if you needed it).

Found this in the help file though re: RANDBETWEEN:

If this function is not available, and returns the #NAME? error, install and load the Analysis ToolPak add-in.

Jim
 
My Excel 2000 help is ambiguous about RANDBETWEEN().

Returns a random number between the numbers you specify....

....RANDBETWEEN(bottom, top)

Bottom is the smallest integer RANDBETWEEN will return.

Top is the largest integer RANDBETWEEN will return.

Does RANDBETWEEN(0,360) ever return 0 or 360?
 
Bottom is the smallest integer RANDBETWEEN will return. Top is the largest integer RANDBETWEEN will return.

...so yes, it will. I just confirmed that by filling a column of 500 cells and searching the resulting output (two 0s and one 360)

Maybe they should have said "Returns a random number within a range of specified numbers". My help file reads the same as yours incidentally.
 
"Within a range" is still sort of ambiguous. It would be better to specify inclusive or exclusive. But I'm just nitpicking. :p
 
"Within a range" is still sort of ambiguous. It would be better to specify inclusive or exclusive. But I'm just nitpicking. :p

I guess that explains why MS never consulted me prior to publishing the help files. I've been pi$$ed about that for years, now I understand. :D
 
I've been using RANDBETWEEN for ages. I regularly get almost every week two numbers in the lottery but never six. So RANDBETWEEN clearly doesn't work :D
vololiberista
 
Back
Top