Follow our Instagram!
Curious about what we're currently doing about bots? Check out the latest updates from staff in this thread.
Welcome to Smogon! Take a moment to read the Introduction to Smogon for a run-down on everything Smogon, and make sure you take some time to read the global rules.

hey everyone.

aurora said:
why am i male frillish man. can i at least have female frillish
Click to expand...Click to collapse...

Lily said:
I don't fully know how to predict it but I've figured out through doing a bunch of name changes that every part of a name changes it; if you go from Bughouse to Bughouse! it'll be different, or bughouse, or BUGHOUSE, or BuGhOuSe, or whatever else. I'm gonna try and dig up what exactly causes it though, this thread has me curious

mine is Sceptile by the way
Click to expand...Click to collapse...
what did you find Lily? aurora needs to know!
Bughouse said:
what did you find Lily? aurora needs to know!
Click to expand...Click to collapse...

The code for default avatars! Thank you to chaos :)

Code:
let AVATARS: string[] = [];

if (process.env.SMOGON_FORUM_AVATAR_DIR) {
    // lib/Avatar::getAvatar
    let dir = process.env.SMOGON_FORUM_AVATAR_DIR;
    if (dir !== 'fake') {
        AVATARS = await fs.readdir(dir);
        // PHP scandir does this
        AVATARS.sort();
        // Recreate bug from forum...
        AVATARS.unshift("..");
        AVATARS.unshift(".");
    }
} else {
    throw new Error(`avatar dir not setup`)
}

function getAvatar(username: string) {
    let crc32 = new CRC32;

    let i = crc32.calculate(username) % AVATARS.length;
    let avatar = AVATARS[i]!;
    return `/forums/media/avatars/${avatar}.m.1`;
}
so basically aurora encodes to some number in decimal via CRC32, and then take that number mod the number of possible options for default avatars there are, and you get your default avatar. but i have no idea from that code how many avatar options there are or what order they're sorted in, so can't help you figure out what sort of name change would get you a default female frillish avatar or indeed any other avatar but I can pretty safely confirm that if you changed to Aurora it at least wouldn't be a male frillish anymore (most likely).
Im whatever this cap mons is... iirc its grass ghost and sucks Necturna but im actually pretty sure i beat yall in a fight. Also first smogoff post... why did we allow cap mons to be defaults :psycry: My mons cry sounds like a Boo but crusty :)
great. bye.
Back Top