#archived-modding-development
1 messages · Page 428 of 1
that's what it was called when I downloaded it a while ago
there was a lot of sadposting today for some reason
oh noez my birthday is sad?
350 messages in 5 hours, that's cute
yes
you haven't seen the time we did that in an hour
there also was a major update to the randomization 
and the hint shop is a bit more polished now
So that's in the 350 messages too
oh boy
well i don't have time right now unfortunately
maybe tomorrow I can catch up. family's in town
@fair rampart wha
drop that dll boi
yes
what
I want to try out your rando
you pinged me
he meant to tag @brazen mortar
you accidently pinged them before
Let me make the modlog a bit better organized and I'll post it
ah
smh 56
it has been processed
but i notice all the minute details
i can notice someone joining voice chat while i'm looking at my 2nd monitor lol
what
sucka
is that using trailrenderer?
particle?
@fair rampart accidentally tagged @waxen ember when he meant to tag @brazen mortar
real particle system hours
smh watcher knights mod that isn't grimm themed
because he is a madlad
I enjoy pinging @unborn goblet
lol
please
@ mods meme pings
saleh stop being an ass
ok Sir
thats "ok Mom" to you young man
"ok Daddy"
no u

I was being polite 😔
wait are you actually annoyed by this?
I thought t'was a joke, if you're really annoyed then I'm sorry (no sarcasm).
@covert arrow
oh wow didn't know that one existed
cease people
anyone with everyone as their nickname is exempt from the no meme ping rule

New randomizer update:
-New randomization system
-Improved dialog in hint shop
-Expanded item logic
adrain did that fix it for you btw
There may be a small stutter on starting a randomized game. Normally randomization takes less than .1s for me, but occasionally it goes up to ~.4s
on GH?
I could go ahead and push this
I had been holding off in case a major flaw was found
yeah
But I doubt I would scrap the whole thing
it's better to do that
no it isn't; other people can find the serious flaw and point at it
...you don't know what you're talking about
yeah I know
lul
you rock homothety
New commit is up. Changes to the randomization are here: https://github.com/homothetyhk/HollowKnight.RandomizerMod/blob/master/RandomizerMod2.0/Randomization/Randomizer.cs

They're a huge mess as boolean expressions, but it makes it much easier to cover every possible scenario
Also makes changing logic across items much easier
Yeah makes it easier to read too, honestly. Rather than some weird polymorphism blah blah blah
oops you mean the logic
Oh, did you mean the while loop on the randomizer?
I like the boolean controls on that too
Haven't gotten in there yet; thought you meant the hint system for where the item is 😃
Oh, oh
I get it now 😄
The things in logic are actually called macros, so that's what confused me
It's dumb because that stuff looks "noobish" but honestly I would prefer stuff to look like that all over the place rather than chopping everything into classes you only use once
Yeah I actually do love the macros in the logic, too. Should make it way easier to read the logic 😃
no
^
@pseudo pewter make it happen
I don't know how to mod
Also this
make it happen
alright
no not you

Rad Markoth in the ascended No Eyes arena when
I can't
role-locked #archived-modding-development when
hydra pale prince when
when you make it
welp, time to do a cyclone slash baldur kill
56 stop
why
hurry up buddy
maybe i should start it too just so you hurry up
im never going to
plus i want to work with particle system™
you go ahead
that's what you think
ill make my version when i feel like it
so never™
if you want i can give you my ideas so you can execute it
56 what mod name
the trick is changing the name at the end
modding idea
anything planned for it so far or is this just a test run thing
i was just bored
imagine being more productive than me while bored
whats the best way to do elder baldurs with cyclone slash
fuck
you can do them with cyclone slash?
Yeah. You just stand at the point where they close and go back and forth
Great Slash doesn't work though
it's really annoyingly precise
o
okay, the first one was a waste of time
because flukenest useless without having vs
so greenpath it is
something that worries me, if hornet doesnt have anything good I have to do cyclone slash baldur shell
thank god, hornet had dive
it's also access to the area under resting grounds
with soul eater
but I cant get to soul eater so it's just a chest
I mean, crystal peaks
although without mantis claw...
what? you can get to cp with dive
oh god I better not have to check quick slash or mato
because I'm not paspid pogoing without anything
that's what you think
unless logic says you need some sort of movement ability to get there
although I guess I could shade skip
which would be easier than paspid pogos
Things which are possible are generally easier than things which are not possible, yes
Though I doubt you have the items for the shade skip either
I might
if I'm good enough at stalling with wraiths
and I could probably also damage boost
hell yeah
I made it

would've been really easy if I had another mask lmao
ngl if I die to a great hopper I'm noclipping past that
all that for lifeblood heart at mato
and idk what yet at qs
I dont think I can get to qs
not with that attitude
I should probably be working on something I need done for school tomorrow rather than talking on discord or doing hk randomizers
❌
thats a fair arguement
imagine going to school
pretty easy to imagine real life
Good luck for your homework
hahanope, not bothering with it
I'll get it done in study hall
Living on the edge
yeah
basically
and I might get some of it done on my phone
while I try to get tired
so Star vs The Forces of Evil just ended
by any chance does anyone follow that series at all?
no
Pog
because I've got some stuff I need to rant about
this is #archived-modding-development not #rant, only serious modding talk here
this but
who was it that asked me to ping them when I was streaming again?
wait I'm still finding it
That emote pairing is incredible
what are you going to stream?
math
sure
yeet skeet
yes math
lemme just start the stream...
it's on sid
@safe hamlet f o o l
no
please this is important
So I'm not seeing a summary for Benchwarp in the doc, someone mind giving me a summary for it?
you can warp to benches you've sat on
from pause menu
okay that makes it super helpful, thanks
someone who is good at time please help me budget this. my family is dying
spend less on first pass items
no
I think there are 3 main time-consuming things which happen during first pass
For every placed item, it has to update this first
Every time it runs out down to one location it calls this
And rarely it has to use this
Everything else is just adding and removing from lists
My gut feeling is the only thing that takes time is calling stuff from logic manager
well you can get rid of the first part !reachedLocations by removing locations as you add them, and you only need to update it if the item has any locked items behind it
I did the first part already, but I can try moving it behind a progression check
what does parselogic do
At init, logic manager parses the logic and stores the boolean expression as a list of strings. Parse logic takes that list and evaluates it as a stack, using the obtained[] argument
strnig comparisons are kinda slow
That seems like it might have shaved some off? The last three tests were all ~ .25 s
you could probably do all your comparisons really fast, by converting your requirements + obtained to a number like say your items are just claw, dash, djump and cdash
say you have claw + djump can do obtained = 1 + 0 + 4 + 0
then for requirements, says its just claw thats 1 + 0 + 0 + 0
then if requirements & obtained = requirements its reachable
Unfortunately, most items depend on over ~20 bools logically right now
So I don't think there's an efficient way to convert that to an enum
Anything outside the top left corner of the map has a billion routes and settings involved (metaphorically)
Thanks for the suggestions though!
I think I found where the lag spikes are 
Basically this if tree
I added too many comments oh noes 😱
Not that
You're just solidifying the point that I'm the only one who doesn't comment his code
I know I should
But I just don't care enough
Yup. I would say GetProgressionItems is the culprit
well you have an array copy straight away, thats nice
I can probably shave at least half that time by filtering out all the baldur kill items and duplicate spells/etc
And maybe more with some creative way to retain which locations we confirmed each progression to give access to, to be able to skip at least some tests on the next call
you could probably make the function noticably faster just by making obtained into a list
and not even using obtained at all
the people in art just called me a code monkey
and just adding to obtainedItems, then removing right after
Still has to convert to array for ParseLogic, but I see what you're saying
private static List<string> GetProgressionItems(int reachableCount)
{
List<string> progression = new List<string>();
foreach (string str in unobtainedItems)
{
if (LogicManager.GetItemDef(str).progression)
{
int hypothetical = 0;
obtainedItems.Add(str);
foreach (string item in unobtainedLocations)
{
if (LogicManager.ParseLogic(item, obtained))
{
hypothetical++;
}
}
obtainedItems.Remove(str);
if (hypothetical > reachableCount)
{
progression.Add(str);
}
}
}
return progression;
}
i mean parselogic should be able to take a list
Yeah, I could clone it with a list argument
you can still do
List<string> whatever;
whatever[x];
i mean you'd have to replace the default one anyway
and make obtained a list
it shouldn't be an array anyway, as it isn't a static size
Yeah, the only thing ParseLogic even does with obtained is
stack.Push(obtained.Contains(logic[i]));
You could change this all into a bitmask
well you have it as an array probably because the variable you have to pass into it is an array too
Would be way faster
I already said that
Well it's a good idea
Would that not require computing a truth table for each item's logic, essentially?
No
You can still parse the postfix expressions
Just with bitmask tokens instead of strings
Ah, now I see
but you also definitely shouldn't be mallocing an array and copy from another array to it
when you can just use a list
But really the ideal overhaul would be for ParseLogic to take an int argument
Or perhaps convert the obtained list into an int inside its body I suppose
you'd always have it as an int
and just add 2^n when you pick up the items at position n in the list of progression items
Ok, cool. That sounds way faster than the current system
exam done nice
how long until you AWAKEN fully
how long until lazy notices im big fan
no
i feel like you have that on hand at all times
FaSteST fiNGErs in ThE wESt
kdt vs ark would be interesting
check your dms lazy
Zaliant we're not looking for more composers atm :/
we're not looking to add new people period
unless they're like
reeeee
a god tier animator/artist
thats me
i can draw stick figures
gay
lazy. wording.
he's going to come and be like "what do you mean your animation workflow is like this"
like why can't I access sprites, by name 😠
why do I either have to use the animator OR attach every sprite 1 by 1 OR write my own image parser
its a feature
a feature that I can't use their built in atlas + sprite sheet unpacker, and use the name of those subsprites to access them
is the fact the animator for 2d is just the 3d animator, with no effort to actually facilitate features a 2d animation system wants+needs, a feature too
why is animation blending even an option on 2d sprites
how often do you blend between 2 sprites in 2d
KDT make HK 2 Electric Boogaloo
i can't actually program a game buggy enough to be hk2
isn't that what we were doing lazy
shhh shhh shut the fuck up

i think I can avoid getting oob within 2 minutes
I disagree
rb.velocity = new Vector2(xSpeed, rb.velocity.y); is all you need
boi
dun dun duuuuuun
Nice
No way unity will ever fuck it up
I can think of literally 0 unity games with janky physics
its fine we're all fine
and to be fair it all leads back to that vector2 so if I want to change it it'll be easy
the nice thing about unity is its renderer works
what a compliment
they're apparently updating physics quite drastically in the coming months though
something something dots?
not too sure of the specifics
maybe games won't have that trademark unity feel
Someone pls help
Where does modinstaller put uninstalled mods
I made a mod to change the soul cap but accidentally uninstalled it
Like an idiot and now it’s gone from the installer
Wait can I just get a new copy off VS
Galaxy brain
How do I build it to a DLL again
C:\Program Files (x86)\Steam\steamapps\common\Hollow Knight\hollow_knight_Data\Managed\Mods\Disabled @urban olive
hello lock Jeever's dumb ass
rude'
telling someone to go to #archived-modding-help when they're actually talking about modding 
modding-help is installing-mods-help
literally just press the build drop down lock
@urban olive if it's Uninstalled it's gone forever. If it's disabled, it's in the folder zaliant mentioned
Mino and lazy: there's some guy streaming art
You guys should contact them
may i ask why they would contact someone who arts ?
Oh yeah sugar is artsy too
art, sigh
wow someone actually good at art in modding
only mino , not me tbh
i would disagree
don't post art here, this isn't gallery smh
also that's not not really good, at least for my standards
thank you
off topic but there's not a lot in comparing yourself to people less better than you and thinking you're better than them 🤔 it only makes your growth stagnate too
you earned it
eeeeh i guess
i was initially planning to go into art which is why i got really good at it
then i was like 😩 what if i dont
what if you do
it's not something i really like enough to do it as a career honestly
Yeah
I think it's best to keep hobbies as hobbies tbh
Even if they make you some money on the side
improve your hobbies
As soon as a hobby becomes work... It doesn't necessarily stop being fun, but that stops it from being a release, a coping mechanism
^
That's how I see it at least
that's exactly how i feel about it honestly
Because even if you work with something you love doing and love doing what you work with... It's still work, you know? There's still pressure, deadlines, expectations etc.
omega this
also sugar you can most definitely get really good at hobbies. i got way above most hobbyists at art and had a lot of fun w/ it
You still need something to get away
I'm way too lazy for something that requires that much dedication
Badly
i gave up on art for a solid year because i was tired of putting in effort
best comeback ever
I wish I could do that to my phd ngl
sometimes the key to improve your skill , is a small touch . For art like brush settings etc....
Small touch
im speechless
sigh
i hope stuff w/ your phd works out btw
phd 
when things get too serious I like to lighten the mood with a silly joke

yeah, phd
ty mino
it's very stressful
i can imagine
at some points I even stop liking maths altogether
basically what we were just saying
bugün saat
this is not portugese
Doctor Tentacles when?
soon ™
noice
how was your day of birth
what the fuck is doctor tentacles ??
oh yeah
it's me, sugar

I don't get your confusion
also gradow
just do art to destress from math like how i recently dropped art to take maths
who else could it be
I can't, mino
ye i know
I would, if I could
it was pretty good! overshadowed by family visiting, but none of my family celebrates so it was just a normal very busy day. Party's this weekend with my wife's family that actually celebrates.
that's cool!
yeah thanks for asking dudes 😃
yeah as long as you have something to destress with
gradow can you please draw the head of the knight and send it here ?? i wanna see it
See I had a question about commutation relations for a 5x5 rubik's cube the other day. If I'd have known you were a maths dude i would have asked
yea i saw it

I was trying to get that checkerboard quilt pattern thing done and got stuck with a few steps
gradow is the methematics person
the way you write math formulas 
what's wrong with the way I write math formulas sugar?
oh you should see how i solve math problems then
it just slowly devolves into chicken scratch
oh yeah you weren't there last night mino
i had my maths exam :^)
Actually heres the issue. Technically still unproven because I solved the problem a different way
proceeds to solve a math problem
fails at second question
I didn't know how to formalize it to see if it's even possible or not
I think it's impossible but I dont know how to "prove" it
If the moves are numbered 1 through 6, you actually only need 1, 3, 5. And I think there are some more moves you can reduce
No just that one picture
I eventually got the checkerboard done, just using different stuff than in that picture
are they the pieces of the cube?
Yeah it maps to the cube somehow. If you x, y a face, they'd be the pieces 2,2 2,4 4,2 4,4
Mostly I just needed to know if it was possible to take 1243 and change it to 1234 using the moveset on the bottom of the picture
Yeah I made it weird. I have a map for myself on how to take an answer from that picture and translate it to cube
Vaguely ?
or at least how to represent permutations using cycles
like the permutation that takes 1234 to 1324 is given by (2 3)
are you familiar with that notion?
sorry switched devices
np
i'm not actually, but is that "2 switches with 3" or something much different
p!!!!!!!!!!!!NG
so if I reduced the moveset to permutation representations then it would be easier
so (1 2 4) would take 1234 to 2431 because "1 goes to 2, 2 goes to 4 and 4 goes to 1"
y ping
makes sense?
Perfect sense
@unborn goblet
jokes on you, got no pener
REEEEEEEEEEEE
@unborn goblet
I had small pener way before you were born dawg
@unborn goblet
#4897
c** u c***
wha?
wait no
it's a miracle i have children
⎛⎝✘MLGFREAKHD✘⎠⎞
#4897
i wanted to say can u cant
ok, stop this
but holy this looks cool
sure
Thanks gradow I'll see if I can use that
cucc, what does that mean again?
ok, dapper, so basically
you can prove that any permutation of four elements is just composition of permutations of 2 elements
any
in mathsy terms, we say that {(1 2), (1 3), (1 4), (2 3), (2 4), (3 4)} is a spanning set for all permutations of four elements
That's fair, except that with cubing I don't have access to those 2 element permutations
yeah
that's why I wanted to understand your notation
because if it's just taking 1243 to 1234 using the permutations you have written, it should be fairly straightforward if you decompose them into cycles
I only had ((1 2) (3 4)), (1 2 3 4), and (1 4 2 3) or something similar
There's another problem with moves 3 and 4 though in that it moves the "slots" they're supposed to be in
Because it's a full rotation of the cube, no move involved. So it doesn't help move the #s into the right slots
(1 2 3 4)=(1 2)(1 3)(1 4)
(1 4 2 3)=(1 4)(1 2)(1 3)
hmm
yeah, sorry, I'm lost in your notations
Yeah that's fair
I think the moveset is only 1 and 2: Either ((1 2) (3 4)) or ((1 3) (2 4)) or "mirroring" along either axis, and then what I called "Rotation3" where you can pick any corner and rotate the other three, so (1 3 4 2) or (3 2 4 1) or (2 4 3 1) or (2 3 1 4)
I never had like formal maths training beyond calculus, and it's been like a decade or more so my brain thinks bad with stuff
I'm really used to thinking for programming too which doesn't help when I'm trying to get back into math because variables are so similar yet completely different
Really loving this diagram which omits that each top face is glued to the next bottom face, clockwise 😕
I wish I knew how to compute homology for the homology pset due in an hour
Well, we aren't doing homology over Z since our professor decided (correctly) that we couldn't handle modules, but over R so it's kinda easier
homathety
▤▧▥▨▤

I really should learn proper homology/algebraic geometry/algebraic topology
homothety can I ask you a question regarding homology groups?
yeah
though like I said, we're doing homology on vector fields because we're bad at quotients 
that's fine
so, take a non-negatively graded chain complex X
and let H(X) be its chain of homologies
since each X_n is a vector space over a field, say K, we can look at its dual vector space, X_n* := Hom(X_n,K)
this gives us a cochain complex X*
non-negatively graded as well
sounds fair so far?
yeah, I follow
ok
so we can compute the homologies of this cochain complex, H(X*)=ker d/im d
but
let's go back to the original chain complex
we have the following ses defining the homology:
0 ---> Bn(X) ---> Zn(X) ---> Hn(X) ---> 0
so if we restrict our focus to finite dimensional vector spaces, the functor Hom(-,K) is actually a duality and, therefore exact
so we get the following ses
0 ---> Hn(X)* ---> Zn(X)* ---> Bn(X)* ---> 0
So Zn* is just coker d and Bn* is just coim=im (by the first isomorphism theorem)
what's the relation between Hn(X)* and Hn(X*)?
yeah
most places define cohomology as the homology of the cochain
but it seems to me that this is a more natural concept of co-object
are they isomorphic?
are they homotopically equivalent?
what in-
interesting
good old maths
I'm out of here before my trying to understand this rots my brain
I haven't given cochains any thought before, so I don't know what to make of it
in the few examples I tried out, it seems they are in fact equal
but I can't, for the life of me, prove it
or even find a proof on stackexchange even
like, I have this result that I was trying to prove on my dissertation, and I needed cohomology. Using Hn(X*) it was impossible to prove it, but using Hn(X)* it was literally trivial to prove it.
Oh, huh
"impossible" in the sense that I couldn't do it, not that it was a logical contradiction or anything
Yeah, as instinct I would guess that the diagram with the duals commutes, since this all feels well behaved(?) I haven't done anything with cohomology yet though, so I really couldn't say
yeah...
I actually have never taken a formal course on homological algebra
so I am always doubting myself in every step
but I've asked people who know a lot about cohomology and they think those are the same thing, but can't think of a proof either
so for now I'm just assuming they are at least homotopically equivalent, because that's enough for me
since I'm going to localize on homotopies anyway
ty btw
mostly this channel is amazing btw
No u
Gradow are you a CS major
he's doing a phd in maths
I'm a maths major
I’m depressed major
@unborn flicker still have the dll chilling somewheres? Gonna play a bit because I'm lacking motivation today
I'm in class now, but it should be 5th or 6th if you search from:me has:file
on your phone in class hmm
in the front row too
tsk tsk
yesterday at 6 pm pacific sound right?
Modlog.txt
i thought you were a maths major?
Very cool but how does that work in Terraria since this is about that game
No this is RimWorld
ah you mean rain world
Unfortunately, one sometimes must take useless classes Mino
So I am in Measure Theory and Algebraic Topology, at the same time as Physiology and European History
hello people
sid returns
happy 2 am
What are "Long Checks"
Right now: White Palace and Grubberfly
Once minor items are randomized, it will probably include Grimm notch, Colosseum pale ore, and a few other grub/essence rewards
as well as normal pale ores and notches or nah?
?
I always wanted pale ore locations rando'd cuz I suck at low damage
Those were the long items that would be removed
homothety isn't so great? Are you kidding me? When was the last time you saw a modder with such an ability and finesse with C#? Homothety puts modding in another level, and we will be blessed if we ever see a modder with his skill and passion for the game again. 56 breaks records. Saleh breaks records. KDT breaks the rules. You can keep your statistics. I prefer the magic.
bring in the copypasta lads
That's true. If you've ever seen me trying to figure out the difference between a list and array while coding rando on the fly, you've seen true genius
scills
at least you're still modding tho
the rest of the modding staff cant say that
using System.Linq; array.ToList()
It took me an hour once to figure out why .ToList wasn't working
Speaking of data storage and such
Is it possible to add flags to a [flags] enum at runtime?
dynamic enums?
not afaik
that's what I thought
i don't think there's such a concept as dynamic enums in C#, but you could make a dictionary do something similar
Probably easier to just type it up once
@jovial vault but I'm working on room rando ♿
There's not that many progression items
56 youre beyond modding staff you dont count
monkaHmm
So I'll make a [flags] enum which has all the settings and progression items in it
Homothety, make sure to set the values on the enum members
[flags] is just for a nice ToString
And I'll preparse the logic to replace string item names with enum ints
Also technically since enums are just ints you could do a dict
like this, right?
That way converting item names to int to add them in will be easy
like (Obtained) 8 is valid even though there's nothing for 8
Also mino Sean is working on like two mods
so what's the problem with not having it defined for 8?
nothing
ok, that's what I thought
which is why I said you could do it
as long as I'm careful not to have a situation where it adds something invalid
the only downside is no nice ToString and Enum.Parse won't work without defined values I think
Remade enemy rando and a summoner mod
aah i see
What happened to room rando
56
I c
room rando when
also i was doing PoP at school, my laptop died at the final room 🙃
but PoP is not hard tho, it's definitely not as hard as people say it is
with infinite soul totems, it's very doable
@copper nacelle cg2 mod when 🤗
I know that’s the joke
♿
cg2?
o
I made a mod which replaced every enemy with cg2
very nice
the only mod that matters
@unborn flicker so if you're "adding" them at runtime via casts you'll want to store the string to int in a dict because Enum.Parse won't work with members that aren't defined at compile time
Hmmm
I don't expect to add any more progression items
So I think for convenience it will be easier to just type this up once and never have anything break
there's only 30 or so, iirc
And it has to check against them even with vanilla placements, so it wouldn't even vary between settings
so generate it as a dict?
and then perform bitwise operations using the dict to provide values as necessary?
If it's a dictionary of string to int you're still doing string comparisons
I mean store obtained as an int and use the dict to add items to obtained, rather
And use the dict to replace all the strings in each logic with ints at init
monka
Yeah that sounds good
So logic will become a list of "|", "+", and longs as strings, I suppose
Or would it still be slow to convert each long from string back to long?
You could dedicate the first couple bits to the operators
That way there's no strings at all
Ah, perfect
Or a new struct with a token type and operand
Since it's a bit awkward to have operators in the mask
Since I'm a bit inexperienced, could you explain what that means in more detail?
Sorry for the trouble
Why is logic changing to something obscure instead of readable?
you should only need one bit right, just set the most significant bit i.e. negatives as a flag for don't read this as a literal, but an operator
because right now it takes half a second to randomize, freezing the game

because of string comparisons
I don't know if this is really making the code more complex
It just slightly changes how the xml is processed, and what we call to add to obtained items
Ok, so the idea for operands is that I replace "+" with -1 and "|" with -2?
And check that when parsing the logic
and
a&b = a is leagues faster than
while(match || i >= str.Length || i >= str2.Length){
match = str[i] == str2[i];
}
or however string compares are programmed
probably less naively than that but still probably pretty slow
yeah you can do
switch(logic){
case -1: whatever;
case -2: whatever;
default: bitmask;
}
Nice, thanks
aslong as you never use 64 bits
right, ofc
that shouldn't be an issue, I think
private static List<string> GetProgressionItems(int reachableCount)
{
List<string> progression = new List<string>();
string[] obtained = new string[obtainedItems.Count + 1];
obtainedItems.CopyTo(obtained);
foreach (string str in unobtainedItems)
{
if (LogicManager.GetItemDef(str).progression)
{
obtained[obtained.Length - 1] = str;
int hypothetical = 0;
foreach (string item in unobtainedLocations)
{
if (LogicManager.ParseLogic(item, obtained))
{
hypothetical++;
}
}
if (hypothetical > reachableCount)
{
progression.Add(str);
}
}
}
return progression;
}
This code causes the lag issues @shy cloak
It has to parse the logic for a lot of locations for each unplaced progression item whenever it's called
I think it was something like 90% of the randomization time came out of calling this function about 10 times, when I was testing last night
what's reachable count?
reachableCount is the current number of reachable locations
So it's basically brute-forcing a list of all progression items which unlock new locations
yikes
The bitmask seems less scalable, but I guess there are finitely many items that can unlock new locations...
I mean, there's always longlong 
If I'm generating it from the xml data, it won't require code modifications to add new items
You're only iterating over unobtained locations, right?
can't you just break the for loop the first time an item unlocks a location?
I guess in some cases it'll keep going if an item doesn't unlock a location, but it should cut the run time by quite a bit, I would think
No, because there is one unobtained location which is accessible, if this function is called
Oh huh, I guess reachableCount is 1 by definition, if this gets used
It would've been much higher in Sean's version
Oh this is the special case if there's only one location left?
This is the first choice if there's only one location left
If it returns empty, then the randomizer starts guessing
which is actually much less resource intensive
so "unobtainedLocations" is a list of 1 item? or is that something different?
unobtainedLocations is all unobtained locations. This occurs when reachableLocations is 1
You could, but that wouldn't be random
I suppose you could randomly sort the order in which you check items
So I might do that in addition to implementing the bitmask
create a permutation and then draw elements from the list by index
The bitmask is probably the smartest way to do it; I'd probably either leave the wait in or do some weird stuff with the location logic
Reduce the RPN (postfix) to include "true" then reduce the logic if I have an item so it doesn't have to re-parse that logic every time...
I made a console app to play around with post fix logic parsing. Right now it can take a logic string from the xml and return the skips as a new logic string to display to the user
i'm not making sense probably, but I wanted the logic expressed only as the skips, if they were required for a location
For example if I'm looking at this logic: (CLAW + (DASH | SUPERDASH | WINGS | ((FIREBALL | SCREAM) + FIREBALLSKIPS))) | (WINGS + (DASH | ((FIREBALL | SCREAM) + FIREBALLSKIPS)) + SPIKETUNNELS + SHADESKIPS)
And have only DASH, FIREBALL, and WINGS it'll spit back: SHADESKIPS + SPIKETUNNELS
Because those are the skips I would need in order to get to this location
And once again i have contributed nothing to the current convo gg me
hey homothety you should try bitmasks
how would i instantiate specific number of objects and start moving them at the same time? like the radiance nail fan
for loop
giant if block
so i guess first instantiate them and store them and later add the component that moves them?
Why make them before you need them?
i want them to move at the exact same time, instantiate adds a small delay
instantiate then disable, enable them when you're ready
that would require storing tho, wouldn't it?
yeah

I could be wrong in the nail case, but i think most of the stuff in the game is added to the scene by team cherry, and the FSM just enables and moves the thingies
yea there's an object pool spawn for markoth's nail
why a while loop
I'm gonna end up redoing the styling for all of this code anyway
That's fine by me
I have minimal knowledge of conventions or optimality, so I'm happy just to make it work
You can download resharper if you want
Style helper
It has mostly good default settings
But I disagree with some of them
Like using var
I like it
I used to do it until something else told me it was bad
But now resharper is telling me it's good so I'm validated
The only downside to var in any situation is less clarity
It doesn't change compilation at all
If it can't infer the type at compile time it'll tell you not to use var
var is good in one case only imo
If you have some really really stupid data type initializer
Like csharp var thing = new List<Dictionary<string, Dictionary<int, List<string>>>>();
Type is still obvious and it halves the line length
right
Better solution though is to not have that data type
i use var when the type is clear
but then again i don't really pay attention to them most of the times
I have found something stupid
That's every half hour at 60fps
Realistically more like every 5-10 minutes
So if you get a small stutter every 5-10 minutes
Now you know why
interesting
GCManager
wut dat
Garbage Collector Manager
C# normally does handle garbage collection, but GC.Collect forces it
right
You're using += and -= for the bitmask?
Is that the mistake or do you mean something else here?
No the mistake was adding unobtained locations to progression
Yeah, I understand what you're saying
homo what are you doing
There's no failsafe if it tries to add something twice that way
(also if that's not your preferred nickname my bad)
I guess it should be "|" for adding a new item, right?
Yeah |=
Oh neat, that's easy
And for removing &= ~thing
I'll fix that then
I'm changing the way the randomizer parses item logic Lazy
Before it used a ton of string comparisons
But now there's a bitmask
It used to be recursive infix parsing
Probably should've gone further than just fixing that when I did
But it was good enough for the single pass randomization
Hey does anyone know if there's mods other than randomizer that rely on activeSceneChanged and/or sceneLoaded being called directly after initialization?
Because the API preloading is either going to break that or another thing unless I put in a lot of extra work
And if just randomizer is gonna break that's fine, it's a 1 line fix
you mean mods that check for main menu and stuff?
Yeah
Benchwarp uses activeSceneChanged to check for main menu, but it only needs to work after s&q
That's a fix I borrowed from Mantis Gods, iirc, for the savesettings bug
also how does preloading break it?
The Unity pipeline goes
Scene Loaded
|
V
Call Start on MonoBehaviours
|
V
Call activeSceneChanged
The relevant parts here at least
Previously mod loading was done from Start on the OnScreenDebugInfo script
Now it's done from a coroutine after reloading the main menu
So there's literally no way to load the mods in the same part of the pipeline with the current setup, since you can only wait for full frames, not pieces
I could fix it but it's really not worth the effort over adding 1 line to the end of randomizer init
i see
Ok, I think it all works now. Randomization time is pretty much unnoticeable!
The last one in the log doesn't look like it worked properly
There's no items other than the progression
Only skills were randomized for that test
I did skills+charms+keys+easy, skills+charms+keys+geo+hard, skills+mag
I see






