Author Topic: Bot testbed  (Read 40681 times)

Offline spike43884

  • Bot Overlord
  • ****
  • Posts: 656
    • View Profile
Re: Bot testbed
« Reply #15 on: April 06, 2017, 05:28:34 PM »
Quote
Yes they'll be reworked.  One of the archetypes I'm working towards is an "ant" bot that can make colonies by digging out shapes.  Probably also, in addition to nrg, bots need some physical substance (ie: nutrients) to grow that they can only get from shapes.  From some light research, it seems a large part of why rain forests are so biodiverse is that they're energy rich but nutrient poor, so I want to be able to simulate that.

I'm not sure of the specifics yet, but my thought is basically that when a dead bot decays, it leaves behind inorganic blobs that can float around in the sim.  Blobs that touch each other stick together, so over time blobs will combine together to form larger and larger shapes.  Something like that.

In a rainforest style sim most energy would be stored in the bots, not shapes (I do geography, that premise is part of why deforestation of the rainforest is SO bad as growing it back isn't too easy, when the trees are gone, so are the nutrients). Perhaps considering bots and shapes have a volume, express nutrients within them as a "density/concentration", and then when the decay or are dug out, when volume decreases by x amount one unit of nutrient is released. (E.g. when the concentration of glucose is 1 part per 10, once volume decreases by 1, one glucose will be emitted). That system could allow for multiple nutrients to exist simultaneously if you so wished.
Autism can allow so much joy, and at the same time sadness to be seen. Our world is weird, and full of contradiction everywhere, yet somehow at moments seems to come together, and make near perfect sense.

Offline Shadowgod2

  • Bot Destroyer
  • ***
  • Posts: 387
    • View Profile
Re: Bot testbed
« Reply #16 on: April 06, 2017, 06:41:01 PM »
as i understand it that would be the case if you so wished it. consider shapes as the decaying bots with all the energy and nutrients in the bot still there but locked up till another bot picks it up. the nutrients might be everywhere but concentrated in the shapes and living bots, where in the open the nutrients can be livable but not necessarily enough to grow much. at the start of a sim that would be a different story but as time went on less so forcing evolution to diversify and keep those nutrients in circulation in the environment.

i have figured out mirroring, now i can work on the waves..

seg = segment numbers:

const seg 120

seg 2 div 1 add { 10 rand swap store } loop

seg 2 div 1 add { dup ref swap neg seg add 2 add store } loop
« Last Edit: April 08, 2017, 12:14:35 AM by Shadowgod2 »

Offline spike43884

  • Bot Overlord
  • ****
  • Posts: 656
    • View Profile
Re: Bot testbed
« Reply #17 on: April 07, 2017, 04:18:05 PM »
as i understand it that would be the case if you so wished it. consider shapes as the decaying bots with all the energy and nutrients in the bot still there but locked up till another bot picks it up. the nutrients might be everywhere but concentrated in the shapes and living bots, where in the open the nutrients can be livable but not necessarily enough to grow much. at the start of a sim that would be a different story but as time went on less so forcing evolution to diversify and keep those nutrients in circulation in the environment.

Yep, although at the beginning of a sim, the larger proportion of nutrients would be outside of bots (either in shapes or in the general environment). As more life (bots/veggies) exists in a sim, the pool of nutrients is drained (unless an option to periodically add nutrients is added).

That would allow a self-limited mechanism to be able to be implemented as to the amount of bots or veggies that can be sustained by an area, by causing a sim to slowly tend towards a rain-forest style environment if all other conditions are favourable, causing a huge drain on ambient (shape-locked or free) nutrients, allowing for growth to only usually occur as a result of death of other bots or veggies.


I feel it'd also help evolution sims a bit too, as it wouldn't be a case of getting a huge population, but of having a sustainable population and ensuring each bot is effective.
Autism can allow so much joy, and at the same time sadness to be seen. Our world is weird, and full of contradiction everywhere, yet somehow at moments seems to come together, and make near perfect sense.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Re: Bot testbed
« Reply #18 on: April 07, 2017, 05:52:43 PM »
I've uploaded a new version at the top of the thread (A01330) that fixes the render thread crashes.  If you notice any more, send them my way (note you can copy+paste from the exception dialog if the repro is awkward).

Offline Shadowgod2

  • Bot Destroyer
  • ***
  • Posts: 387
    • View Profile
Re: Bot testbed
« Reply #19 on: April 08, 2017, 12:14:05 AM »
i tried the randomizing mirroring code i had above (which i realized wasn't complete for some reason and had fixed) and the render crashed so here's the log:

Code: [Select]
RootLevelException = {
    Description = "System.Exception",
    Message = "Encountered another boundary edge when building monotone polygon for boundary edge.",
    Source = "Annulus.CSG.StraightSkeletonDecompose",
    Stack Trace = {
        File = "\Modules\Annulus\Annulus\CSG\StraightSkeleton.cs:137:25",
        File = "\Modules\Blacklight\Core\Core\Drawables\Polygon.cs:48:13",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:200:17",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:101:13",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:149:17",
    },
    Data = {
        radiiOut = {
            0 = "0.0199909991 //0x3F9478853D64D7A4",
            1 = "0.0109990999 //0x3F8686B23330D729",
            2 = "0.0199909991 //0x3F9478853D64D7A4",
            3 = "0.0199909991 //0x3F9478853D64D7A4",
            4 = "0.0159945995 //0x3F9060E3665F5248",
            5 = "0.0139963996 //0x3F8CAA24F5B91F34",
            6 = "0.0179927993 //0x3F926CB451E214F6",
            7 = "0.0199909991 //0x3F9478853D64D7A4",
            8 = "0.0119981998 //0x3F8892831EB399D7",
            9 = "0.0199909991 //0x3F9478853D64D7A4",
            10 = "0.0119981998 //0x3F8892831EB399D7",
            11 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            12 = "0.0179927993 //0x3F926CB451E214F6",
            13 = "0.0129972997 //0x3F8A9E540A365C85",
            14 = "0.0179927993 //0x3F926CB451E214F6",
            15 = "0.0169936994 //0x3F9166CBDC20B39E",
            16 = "0.0179927993 //0x3F926CB451E214F6",
            17 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            18 = "0.0189918992 //0x3F93729CC7A3764C",
            19 = "0.0169936994 //0x3F9166CBDC20B39E",
            20 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            21 = "0.0169936994 //0x3F9166CBDC20B39E",
            22 = "0.0129972997 //0x3F8A9E540A365C85",
            23 = "0.0129972997 //0x3F8A9E540A365C85",
            24 = "0.0199909991 //0x3F9478853D64D7A4",
            25 = "0.0169936994 //0x3F9166CBDC20B39E",
            26 = "0.0159945995 //0x3F9060E3665F5248",
            27 = "0.0139963996 //0x3F8CAA24F5B91F34",
            28 = "0.0119981998 //0x3F8892831EB399D7",
            29 = "0.0159945995 //0x3F9060E3665F5248",
            30 = "0.0109990999 //0x3F8686B23330D729",
            31 = "0.0109990999 //0x3F8686B23330D729",
            32 = "0.0139963996 //0x3F8CAA24F5B91F34",
            33 = "0.0179927993 //0x3F926CB451E214F6",
            34 = "0.0159945995 //0x3F9060E3665F5248",
            35 = "0.0109990999 //0x3F8686B23330D729",
            36 = "0.0199909991 //0x3F9478853D64D7A4",
            37 = "0.0159945995 //0x3F9060E3665F5248",
            38 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            39 = "0.0129972997 //0x3F8A9E540A365C85",
            40 = "0.0189918992 //0x3F93729CC7A3764C",
            41 = "0.0189918992 //0x3F93729CC7A3764C",
            42 = "0.0139963996 //0x3F8CAA24F5B91F34",
            43 = "0.0169936994 //0x3F9166CBDC20B39E",
            44 = "0.0169936994 //0x3F9166CBDC20B39E",
            45 = "0.0199909991 //0x3F9478853D64D7A4",
            46 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            47 = "0.0119981998 //0x3F8892831EB399D7",
            48 = "0.0139963996 //0x3F8CAA24F5B91F34",
            49 = "0.0129972997 //0x3F8A9E540A365C85",
            50 = "0.0189918992 //0x3F93729CC7A3764C",
            51 = "0.0129972997 //0x3F8A9E540A365C85",
            52 = "0.0139963996 //0x3F8CAA24F5B91F34",
            53 = "0.0119981998 //0x3F8892831EB399D7",
            54 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            55 = "0.0199909991 //0x3F9478853D64D7A4",
            56 = "0.0169936994 //0x3F9166CBDC20B39E",
            57 = "0.0169936994 //0x3F9166CBDC20B39E",
            58 = "0.0139963996 //0x3F8CAA24F5B91F34",
            59 = "0.0189918992 //0x3F93729CC7A3764C",
            60 = "0.0189918992 //0x3F93729CC7A3764C",
            61 = "0.0129972997 //0x3F8A9E540A365C85",
            62 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            63 = "0.0159945995 //0x3F9060E3665F5248",
            64 = "0.0199909991 //0x3F9478853D64D7A4",
            65 = "0.0109990999 //0x3F8686B23330D729",
            66 = "0.0159945995 //0x3F9060E3665F5248",
            67 = "0.0179927993 //0x3F926CB451E214F6",
            68 = "0.0139963996 //0x3F8CAA24F5B91F34",
            69 = "0.0109990999 //0x3F8686B23330D729",
            70 = "0.0109990999 //0x3F8686B23330D729",
            71 = "0.0159945995 //0x3F9060E3665F5248",
            72 = "0.0119981998 //0x3F8892831EB399D7",
            73 = "0.0139963996 //0x3F8CAA24F5B91F34",
            74 = "0.0159945995 //0x3F9060E3665F5248",
            75 = "0.0169936994 //0x3F9166CBDC20B39E",
            76 = "0.0199909991 //0x3F9478853D64D7A4",
            77 = "0.0129972997 //0x3F8A9E540A365C85",
            78 = "0.0129972997 //0x3F8A9E540A365C85",
            79 = "0.0169936994 //0x3F9166CBDC20B39E",
            80 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            81 = "0.0169936994 //0x3F9166CBDC20B39E",
            82 = "0.0189918992 //0x3F93729CC7A3764C",
            83 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            84 = "0.0179927993 //0x3F926CB451E214F6",
            85 = "0.0169936994 //0x3F9166CBDC20B39E",
            86 = "0.0179927993 //0x3F926CB451E214F6",
            87 = "0.0129972997 //0x3F8A9E540A365C85",
            88 = "0.0179927993 //0x3F926CB451E214F6",
            89 = "0.0149954995 //0x3F8EB5F5E13BE1E1",
            90 = "0.0119981998 //0x3F8892831EB399D7",
            91 = "0.0199909991 //0x3F9478853D64D7A4",
            92 = "0.0119981998 //0x3F8892831EB399D7",
            93 = "0.0199909991 //0x3F9478853D64D7A4",
            94 = "0.0179927993 //0x3F926CB451E214F6",
            95 = "0.0139963996 //0x3F8CAA24F5B91F34",
            96 = "0.0159945995 //0x3F9060E3665F5248",
            97 = "0.0199909991 //0x3F9478853D64D7A4",
            98 = "0.0199909991 //0x3F9478853D64D7A4",
            99 = "0.0109990999 //0x3F8686B23330D729",
        },
    },
}

hopefully ill get a basic swimmer tonight.. ill edit to here if no one posts like usual..

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Re: Bot testbed
« Reply #20 on: April 08, 2017, 02:33:36 PM »
Okay, fixed that render crash too.  New version is at the top of the thread.

Offline Botsareus

  • Society makes it all backwards - there is a good reason for that
  • Bot God
  • *****
  • Posts: 4483
    • View Profile
Re: Bot testbed
« Reply #21 on: April 08, 2017, 06:11:11 PM »
I like to simply point out that sin and cos use the full integer range in db2 because the result is multiplied by 32000. Therefore if you divide sin by cos you would get some decent but not perfect results.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Re: Bot testbed
« Reply #22 on: April 08, 2017, 07:20:04 PM »
I'm not against changing the range, as long as it's a multiple of 360 (so the mapping to degrees is easy).  How do people feel about mapping [0, 360] degrees to [0, 9720], since the max range of memory is 9999?  I wouldn't want to go higher, even though the stack has 9 digits, since you couldn't store the result easily in memory.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Re: Bot testbed
« Reply #23 on: April 08, 2017, 07:29:26 PM »
Oh, I've also uploaded a new version.  Change list and new binary at the top.

Offline Shadowgod2

  • Bot Destroyer
  • ***
  • Posts: 387
    • View Profile
Re: Bot testbed
« Reply #24 on: April 08, 2017, 10:24:30 PM »
i have me a crude swimmer :D finally..
Code: [Select]
const seg 120
const maxh 20
const minh 5
const timer 10
'1 is always maxed
maxh 10 add .1

'wave up if count is 0 and prev seg is not 0ed

seg 2 div 1 add {
 dup 300 add ref sgn abs neg 1 add mul
 dup 1 sub ref minh sub sgn 1 sub sgn 1 add mul
 dup dup ref maxh swap sub 2 div swap ref add 1 add swap store } loop

'wave down if at or above max hight or -1 counter

seg 2 div 1 add {
 dup dup 300 add ref sgn 1 add sgn neg 1 add swap
 ref maxh sub sgn 1 add sgn add sgn mul
 dup dup dup ref swap ref  minh sub 2 div 1 add sub swap store
-1 swap 300 add store } loop

'count down from 3 to 0 when 0ed, 0 starts the wave, -1 is reverse on wave
''set timer to x if 0ed and timer is -1

seg 2 div 1 add {
dup ref minh swap sub sgn 1 add sgn mul
dup 300 add ref sgn 1 add sgn neg 1 add mul
300 add timer swap store } loop

''count down

seg 2 div 1 add {
300 add dup ref sgn 1 sub sgn 1 add mul
dup ref 1 sub swap store } loop

'mirror other side
seg 2 div 1 add { dup ref swap neg seg add 2 add store } loop

basic but good enough to test with.. now lets see if i can get an ellipse as the minh to weigh against for a better looking movement in the waves
« Last Edit: April 08, 2017, 10:34:46 PM by Shadowgod2 »

Offline Shadowgod2

  • Bot Destroyer
  • ***
  • Posts: 387
    • View Profile
Re: Bot testbed
« Reply #25 on: April 08, 2017, 10:48:52 PM »
ok this crash came out of no where while i was messing with the settings on the new bot:
Code: [Select]
RootLevelException = {
    Description = "System.Exception",
    Message = "Encountered another boundary edge when building monotone polygon for boundary edge.",
    Source = "Annulus.CSG.StraightSkeletonDecompose",
    Stack Trace = {
        File = "\Modules\Annulus\Annulus\CSG\StraightSkeleton.cs:137:25",
        File = "\Modules\Blacklight\Core\Core\Drawables\Polygon.cs:48:13",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:200:17",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:101:13",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:149:17",
    },
    Data = {
        radiiOut = {
            0 = "0.0889288929 //0x3FB6C40B3EA10505",
            1 = "0.0619531953 //0x3FAFB854478F67F6",
            2 = "0.064950495 //0x3FB0A0987C18BCFC",
            3 = "0.0709450945 //0x3FB229752CBACEFE",
            4 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            5 = "0.1079117912 //0x3FBBA01B6DF79363",
            6 = "0.1049144914 //0x3FBADBAD15A68A62",
            7 = "0.098919892 //0x3FB952D06504785F",
            8 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            9 = "0.0599549955 //0x3FAEB26BD1CE069F",
            10 = "0.0619531953 //0x3FAFB854478F67F6",
            11 = "0.064950495 //0x3FB0A0987C18BCFC",
            12 = "0.0709450945 //0x3FB229752CBACEFE",
            13 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            14 = "0.1079117912 //0x3FBBA01B6DF79363",
            15 = "0.1049144914 //0x3FBADBAD15A68A62",
            16 = "0.098919892 //0x3FB952D06504785F",
            17 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            18 = "0.0599549955 //0x3FAEB26BD1CE069F",
            19 = "0.0619531953 //0x3FAFB854478F67F6",
            20 = "0.064950495 //0x3FB0A0987C18BCFC",
            21 = "0.0709450945 //0x3FB229752CBACEFE",
            22 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            23 = "0.1079117912 //0x3FBBA01B6DF79363",
            24 = "0.1049144914 //0x3FBADBAD15A68A62",
            25 = "0.098919892 //0x3FB952D06504785F",
            26 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            27 = "0.0599549955 //0x3FAEB26BD1CE069F",
            28 = "0.0619531953 //0x3FAFB854478F67F6",
            29 = "0.064950495 //0x3FB0A0987C18BCFC",
            30 = "0.0709450945 //0x3FB229752CBACEFE",
            31 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            32 = "0.1079117912 //0x3FBBA01B6DF79363",
            33 = "0.1049144914 //0x3FBADBAD15A68A62",
            34 = "0.098919892 //0x3FB952D06504785F",
            35 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            36 = "0.0599549955 //0x3FAEB26BD1CE069F",
            37 = "0.0619531953 //0x3FAFB854478F67F6",
            38 = "0.064950495 //0x3FB0A0987C18BCFC",
            39 = "0.0709450945 //0x3FB229752CBACEFE",
            40 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            41 = "0.1079117912 //0x3FBBA01B6DF79363",
            42 = "0.1049144914 //0x3FBADBAD15A68A62",
            43 = "0.098919892 //0x3FB952D06504785F",
            44 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            45 = "0.0599549955 //0x3FAEB26BD1CE069F",
            46 = "0.0619531953 //0x3FAFB854478F67F6",
            47 = "0.064950495 //0x3FB0A0987C18BCFC",
            48 = "0.0709450945 //0x3FB229752CBACEFE",
            49 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            50 = "0.1079117912 //0x3FBBA01B6DF79363",
            51 = "0.1049144914 //0x3FBADBAD15A68A62",
            52 = "0.098919892 //0x3FB952D06504785F",
            53 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            54 = "0.0599549955 //0x3FAEB26BD1CE069F",
            55 = "0.0619531953 //0x3FAFB854478F67F6",
            56 = "0.064950495 //0x3FB0A0987C18BCFC",
            57 = "0.0709450945 //0x3FB229752CBACEFE",
            58 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            59 = "0.1079117912 //0x3FBBA01B6DF79363",
            60 = "0.1049144914 //0x3FBADBAD15A68A62",
            61 = "0.1079117912 //0x3FBBA01B6DF79363",
            62 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            63 = "0.0709450945 //0x3FB229752CBACEFE",
            64 = "0.064950495 //0x3FB0A0987C18BCFC",
            65 = "0.0619531953 //0x3FAFB854478F67F6",
            66 = "0.0599549955 //0x3FAEB26BD1CE069F",
            67 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            68 = "0.098919892 //0x3FB952D06504785F",
            69 = "0.1049144914 //0x3FBADBAD15A68A62",
            70 = "0.1079117912 //0x3FBBA01B6DF79363",
            71 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            72 = "0.0709450945 //0x3FB229752CBACEFE",
            73 = "0.064950495 //0x3FB0A0987C18BCFC",
            74 = "0.0619531953 //0x3FAFB854478F67F6",
            75 = "0.0599549955 //0x3FAEB26BD1CE069F",
            76 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            77 = "0.098919892 //0x3FB952D06504785F",
            78 = "0.1049144914 //0x3FBADBAD15A68A62",
            79 = "0.1079117912 //0x3FBBA01B6DF79363",
            80 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            81 = "0.0709450945 //0x3FB229752CBACEFE",
            82 = "0.064950495 //0x3FB0A0987C18BCFC",
            83 = "0.0619531953 //0x3FAFB854478F67F6",
            84 = "0.0599549955 //0x3FAEB26BD1CE069F",
            85 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            86 = "0.098919892 //0x3FB952D06504785F",
            87 = "0.1049144914 //0x3FBADBAD15A68A62",
            88 = "0.1079117912 //0x3FBBA01B6DF79363",
            89 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            90 = "0.0709450945 //0x3FB229752CBACEFE",
            91 = "0.064950495 //0x3FB0A0987C18BCFC",
            92 = "0.0619531953 //0x3FAFB854478F67F6",
            93 = "0.0599549955 //0x3FAEB26BD1CE069F",
            94 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            95 = "0.098919892 //0x3FB952D06504785F",
            96 = "0.1049144914 //0x3FBADBAD15A68A62",
            97 = "0.1079117912 //0x3FBBA01B6DF79363",
            98 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            99 = "0.0709450945 //0x3FB229752CBACEFE",
            100 = "0.064950495 //0x3FB0A0987C18BCFC",
            101 = "0.0619531953 //0x3FAFB854478F67F6",
            102 = "0.0599549955 //0x3FAEB26BD1CE069F",
            103 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            104 = "0.098919892 //0x3FB952D06504785F",
            105 = "0.1049144914 //0x3FBADBAD15A68A62",
            106 = "0.1079117912 //0x3FBBA01B6DF79363",
            107 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            108 = "0.0709450945 //0x3FB229752CBACEFE",
            109 = "0.064950495 //0x3FB0A0987C18BCFC",
            110 = "0.0619531953 //0x3FAFB854478F67F6",
            111 = "0.0599549955 //0x3FAEB26BD1CE069F",
            112 = "0.0859315932 //0x3FB5FF9CE64FFC05",
            113 = "0.098919892 //0x3FB952D06504785F",
            114 = "0.1049144914 //0x3FBADBAD15A68A62",
            115 = "0.1079117912 //0x3FBBA01B6DF79363",
            116 = "0.0839333933 //0x3FB57CA8AB6F4B59",
            117 = "0.0709450945 //0x3FB229752CBACEFE",
            118 = "0.064950495 //0x3FB0A0987C18BCFC",
            119 = "0.0619531953 //0x3FAFB854478F67F6",
        },
    },
}

Offline spike43884

  • Bot Overlord
  • ****
  • Posts: 656
    • View Profile
Re: Bot testbed
« Reply #26 on: April 09, 2017, 04:14:37 AM »
I'm not against changing the range, as long as it's a multiple of 360 (so the mapping to degrees is easy).  How do people feel about mapping [0, 360] degrees to [0, 9720], since the max range of memory is 9999?  I wouldn't want to go higher, even though the stack has 9 digits, since you couldn't store the result easily in memory.

Do 9900 perhaps as it's a multiple of 180 (which is half of 360) -> 55*180 = 9999

You can't get any closer to 9999 via 90, 45 or 22.5 multiples.
Also, I can't imagine you using 9999 memory locations (though, I may be wrong) so if you then made it so memory locations greater than 9900 (those which can't standardly be selected by cos/sin) as custom memory locations, for people to store their own data in (including epigenetic locations?) - 99 in most cases should be enough.
« Last Edit: April 09, 2017, 04:18:55 AM by spike43884 »
Autism can allow so much joy, and at the same time sadness to be seen. Our world is weird, and full of contradiction everywhere, yet somehow at moments seems to come together, and make near perfect sense.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Re: Bot testbed
« Reply #27 on: April 09, 2017, 07:57:08 AM »
i have me a crude swimmer :D finally..

Ah, it's pretty sweet :)  I haven't started with fluid stuff yet (fixing all the crashes you've been finding), but soon.

Quote from: spike43884
Do 9900 perhaps as it's a multiple of 180 (which is half of 360) -> 55*180 = 9999

Problem is you can't represent 45 degrees if 360->9900 (since 9900 doesn't divide evenly in to 8 parts), and that's a fairly important angle.

Quote
Also, I can't imagine you using 9999 memory locations (though, I may be wrong) so if you then made it so memory locations greater than 9900 (those which can't standardly be selected by cos/sin) as custom memory locations, for people to store their own data in (including epigenetic locations?) - 99 in most cases should be enough.

At the moment there are only 999 memory locations.  I'll probably expand that to 9999 at some point, but point is don't confuse how many memory slots there are (999) with what values they can store ([-9999, 9999]).

At some point I'll reserve a large contiguous memory block for user use.  At the moment I'm not sure how many sysvars I'll need for normal bot stuff yet, so I don't want to jump on to segmenting up the memory just yet.

Offline Shadowgod2

  • Bot Destroyer
  • ***
  • Posts: 387
    • View Profile
Re: Bot testbed
« Reply #28 on: April 09, 2017, 09:17:15 AM »
im fine with what ever for the angles but the memlocs as the dna stands now is easy to use up so i would recommend at least 300 being user use, probably more, but we'll cross that bridge when we get to it. one step at a time


 :glare: yet another bug report, why are new programs always so buggy, especially the fun ones:
Code: [Select]
RootLevelException = {
    Description = "System.Exception",
    Message = "Encountered another boundary edge when building monotone polygon for boundary edge.",
    Source = "Annulus.CSG.StraightSkeletonDecompose",
    Stack Trace = {
        File = "\Modules\Annulus\Annulus\CSG\StraightSkeleton.cs:137:25",
        File = "\Modules\Blacklight\Core\Core\Drawables\Polygon.cs:48:13",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:200:17",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:101:13",
        File = "\Modules\Darwinbots3\Bot.Testbed\Renderer.cs:149:17",
    },
    Data = {
        radiiOut = {
            0 = "0.0439693969 //0x3FA6832823C2FBE6",
            1 = "0.0599549955 //0x3FAEB26BD1CE069F",
            2 = "0.0299819982 //0x3F9EB399D6F2A50A",
            3 = "0.0329792979 //0x3FA0E2A99C1B6487",
            4 = "0.0289828983 //0x3F9DADB1613143B4",
            5 = "0.0309810981 //0x3F9FB9824CB40660",
            6 = "0.0289828983 //0x3F9DADB1613143B4",
            7 = "0.0489648965 //0x3FA911ED4A266F40",
            8 = "0.0329792979 //0x3FA0E2A99C1B6487",
            9 = "0.0309810981 //0x3F9FB9824CB40660",
            10 = "0.0329792979 //0x3FA0E2A99C1B6487",
            11 = "0.0289828983 //0x3F9DADB1613143B4",
            12 = "0.0299819982 //0x3F9EB399D6F2A50A",
            13 = "0.0559585959 //0x3FACA69AE64B43F0",
            14 = "0.0569576958 //0x3FAD298F212BF49C",
            15 = "0.0549594959 //0x3FAC23A6AB6A9345",
            16 = "0.0289828983 //0x3F9DADB1613143B4",
            17 = "0.0339783978 //0x3FA1659DD6FC1533",
            18 = "0.031980198 //0x3FA05FB5613AB3DC",
            19 = "0.0279837984 //0x3F9CA7C8EB6FE25C",
            20 = "0.0389738974 //0x3FA3F462FD5F888C",
            21 = "0.0299819982 //0x3F9EB399D6F2A50A",
            22 = "0.0309810981 //0x3F9FB9824CB40660",
            23 = "0.0549594959 //0x3FAC23A6AB6A9345",
            24 = "0.0529612961 //0x3FAB1DBE35A931EE",
            25 = "0.053960396 //0x3FABA0B27089E299",
            26 = "0.0439693969 //0x3FA6832823C2FBE6",
            27 = "0.0579567957 //0x3FADAC835C0CA548",
            28 = "0.0309810981 //0x3F9FB9824CB40660",
            29 = "0.0279837984 //0x3F9CA7C8EB6FE25C",
            30 = "0.0299819982 //0x3F9EB399D6F2A50A",
            31 = "0.0329792979 //0x3FA0E2A99C1B6487",
            32 = "0.0349774977 //0x3FA1E89211DCC5DF",
            33 = "0.0329792979 //0x3FA0E2A99C1B6487",
            34 = "0.0309810981 //0x3F9FB9824CB40660",
            35 = "0.0279837984 //0x3F9CA7C8EB6FE25C",
            36 = "0.0289828983 //0x3F9DADB1613143B4",
            37 = "0.0329792979 //0x3FA0E2A99C1B6487",
            38 = "0.0339783978 //0x3FA1659DD6FC1533",
            39 = "0.0309810981 //0x3F9FB9824CB40660",
            40 = "0.0479657966 //0x3FA88EF90F45BE95",
            41 = "0.0449684968 //0x3FA7061C5EA3AC92",
            42 = "0.0379747975 //0x3FA3716EC27ED7E1",
            43 = "0.0299819982 //0x3F9EB399D6F2A50A",
            44 = "0.0289828983 //0x3F9DADB1613143B4",
            45 = "0.0329792979 //0x3FA0E2A99C1B6487",
            46 = "0.0299819982 //0x3F9EB399D6F2A50A",
            47 = "0.031980198 //0x3FA05FB5613AB3DC",
            48 = "0.0299819982 //0x3F9EB399D6F2A50A",
            49 = "0.0309810981 //0x3F9FB9824CB40660",
            50 = "0.0299819982 //0x3F9EB399D6F2A50A",
            51 = "0.0309810981 //0x3F9FB9824CB40660",
            52 = "0.0309810981 //0x3F9FB9824CB40660",
            53 = "0.0379747975 //0x3FA3716EC27ED7E1",
            54 = "0.0299819982 //0x3F9EB399D6F2A50A",
            55 = "0.0329792979 //0x3FA0E2A99C1B6487",
            56 = "0.0369756976 //0x3FA2EE7A879E2736",
            57 = "0.0579567957 //0x3FADAC835C0CA548",
            58 = "0.0569576958 //0x3FAD298F212BF49C",
            59 = "0.0329792979 //0x3FA0E2A99C1B6487",
            60 = "0.0329792979 //0x3FA0E2A99C1B6487",
            61 = "0.0329792979 //0x3FA0E2A99C1B6487",
            62 = "0.0569576958 //0x3FAD298F212BF49C",
            63 = "0.0579567957 //0x3FADAC835C0CA548",
            64 = "0.0369756976 //0x3FA2EE7A879E2736",
            65 = "0.0329792979 //0x3FA0E2A99C1B6487",
            66 = "0.0299819982 //0x3F9EB399D6F2A50A",
            67 = "0.0379747975 //0x3FA3716EC27ED7E1",
            68 = "0.0309810981 //0x3F9FB9824CB40660",
            69 = "0.0309810981 //0x3F9FB9824CB40660",
            70 = "0.0299819982 //0x3F9EB399D6F2A50A",
            71 = "0.0309810981 //0x3F9FB9824CB40660",
            72 = "0.0299819982 //0x3F9EB399D6F2A50A",
            73 = "0.031980198 //0x3FA05FB5613AB3DC",
            74 = "0.0299819982 //0x3F9EB399D6F2A50A",
            75 = "0.0329792979 //0x3FA0E2A99C1B6487",
            76 = "0.0289828983 //0x3F9DADB1613143B4",
            77 = "0.0299819982 //0x3F9EB399D6F2A50A",
            78 = "0.0379747975 //0x3FA3716EC27ED7E1",
            79 = "0.0449684968 //0x3FA7061C5EA3AC92",
            80 = "0.0479657966 //0x3FA88EF90F45BE95",
            81 = "0.0309810981 //0x3F9FB9824CB40660",
            82 = "0.0339783978 //0x3FA1659DD6FC1533",
            83 = "0.0329792979 //0x3FA0E2A99C1B6487",
            84 = "0.0289828983 //0x3F9DADB1613143B4",
            85 = "0.0279837984 //0x3F9CA7C8EB6FE25C",
            86 = "0.0309810981 //0x3F9FB9824CB40660",
            87 = "0.0329792979 //0x3FA0E2A99C1B6487",
            88 = "0.0349774977 //0x3FA1E89211DCC5DF",
            89 = "0.0329792979 //0x3FA0E2A99C1B6487",
            90 = "0.0299819982 //0x3F9EB399D6F2A50A",
            91 = "0.0279837984 //0x3F9CA7C8EB6FE25C",
            92 = "0.0309810981 //0x3F9FB9824CB40660",
            93 = "0.0579567957 //0x3FADAC835C0CA548",
            94 = "0.0439693969 //0x3FA6832823C2FBE6",
            95 = "0.053960396 //0x3FABA0B27089E299",
            96 = "0.0529612961 //0x3FAB1DBE35A931EE",
            97 = "0.0549594959 //0x3FAC23A6AB6A9345",
            98 = "0.0309810981 //0x3F9FB9824CB40660",
            99 = "0.0299819982 //0x3F9EB399D6F2A50A",
            100 = "0.0389738974 //0x3FA3F462FD5F888C",
            101 = "0.0279837984 //0x3F9CA7C8EB6FE25C",
            102 = "0.031980198 //0x3FA05FB5613AB3DC",
            103 = "0.0339783978 //0x3FA1659DD6FC1533",
            104 = "0.0289828983 //0x3F9DADB1613143B4",
            105 = "0.0549594959 //0x3FAC23A6AB6A9345",
            106 = "0.0569576958 //0x3FAD298F212BF49C",
            107 = "0.0559585959 //0x3FACA69AE64B43F0",
            108 = "0.0299819982 //0x3F9EB399D6F2A50A",
            109 = "0.0289828983 //0x3F9DADB1613143B4",
            110 = "0.0329792979 //0x3FA0E2A99C1B6487",
            111 = "0.0309810981 //0x3F9FB9824CB40660",
            112 = "0.0329792979 //0x3FA0E2A99C1B6487",
            113 = "0.0489648965 //0x3FA911ED4A266F40",
            114 = "0.0289828983 //0x3F9DADB1613143B4",
            115 = "0.0309810981 //0x3F9FB9824CB40660",
            116 = "0.0289828983 //0x3F9DADB1613143B4",
            117 = "0.0329792979 //0x3FA0E2A99C1B6487",
            118 = "0.0299819982 //0x3F9EB399D6F2A50A",
            119 = "0.0599549955 //0x3FAEB26BD1CE069F",
        },
    },
}
« Last Edit: April 09, 2017, 09:38:42 AM by Shadowgod2 »

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Re: Bot testbed
« Reply #29 on: April 09, 2017, 10:15:46 AM »
Okay, new binary at the top that fixes all the render crashes you've posted so far.

If it's any consolation, I'm adding all the crashes you find to a big testing framework so each crash you find is some completely novel way of crashing things :)