15 årig scout, tycker om nyheter, politik och datorer (FOSS)

  • 8 Posts
  • 217 Comments
Joined 1 year ago
cake
Cake day: September 20th, 2023

help-circle







  • nice game! although I feel like some of the setups in tumbling ballistic are impossible to beat, although there just random. Anyways, here’s my very messy code:

    // Arguments:
    let {x_position, altitude, angle, userStore} = arguments[0];
    
    let target_angle = 0
    let x_thrust = 0
    
    ///////////////
    // Side slip //
    ///////////////
    
    let half = 159
    let ms = 400
    let target_speed = ((half - x_position) / half) * ms
    
    if (altitude < 150 || target_speed < 0.1 * ms)
      target_speed = 0
    
    if (!("px" in userStore)) {
      userStore.px = x_position
    }
    let dx = userStore.px - x_position
    userStore.px = x_position
    let xs = dx * 60 + target_speed
    let axs = xs > 0 ? xs : -xs
    
    target_angle = axs < 90 ? xs : 90 * (xs / axs)
    x_thrust = (axs / 90) * (target_angle  > 0 ? target_angle : -target_angle) * 1
    if (x_thrust > 1) {
      x_thrust = 1
    }
    x_thrust = x_thrust * ((target_angle  > 0 ? target_angle : -target_angle) / 90)
    
    let atas = altitude < 150 ? altitude / 150 : 1
    target_angle *= atas
    
    let ad = target_angle - angle
    let aad = ad > 0 ? ad : -ad
    
    let aa = angle > 0 ? angle : -angle
    
    let xtc90 = altitude < 500 ? (altitude / 500) * 30 : 30
    
    if (aa > 90 + xtc90 || aad > 45 || altitude < 200) {
      x_thrust = 0
    }
    
    //////////////
    // Altitude //
    //////////////
    
    if (!("da" in userStore)) {
      userStore.da = 0;
    }
    if (!("pa" in userStore)) {
      userStore.pa = altitude;
    }
    
    userStore.da = userStore.pa - altitude
    userStore.pa = altitude
    let as = userStore.da * 60
    
    let tas = altitude / 1.35 + 0.2
    let thrust = 0
    if (as > tas) {
      thrust = 1
    }
    let acb = 200 + (as > 250 ? 100 : 0)
    let angle_cutoff = altitude < acb ? 89 * (as / 200) : 35
    if (angle_cutoff > 89) angle_cutoff = 89
    if ((angle > 0 ? angle : -angle) > angle_cutoff) {
      thrust = 0
    }
    
    thrust += x_thrust
    if (thrust > 1) {
      thrust = 1
    }
    
    //////////////
    // Rotation //
    //////////////
    
    if (!("dr" in userStore)) {
      userStore.dr = 0;
    }
    if (!("pr" in userStore)) {
      userStore.pr = angle;
    }
    
    userStore.dr = userStore.pr - angle
    userStore.pr = angle
    let rs = userStore.dr * 60
    let ars = rs > 0 ? rs : -rs
    let rsrtm = 0.02
    let rt = (-(angle - target_angle) / 360) * 10 + rs * rsrtm
    
    let ardmc = 50
    if (ars < 30) ardmc = 0
    
    let rd = angle - target_angle
    let ard = (rd > 0 ? rs : -rd) + rs * ardmc
    
    let ard180_1 = 180 - (angle > 0 ? angle : -angle)
    let ard180_2 = 180 - (target_angle > 0 ? target_angle : -target_angle)
    let ard180 = ard180_1 + ard180_2 - rs * ardmc
    
    if (((target_angle > 0) != (angle > 0)) && ard180 < ard && false) {
      rt -= rs * rsrtm
      rt = -rt 
    }
    
    if (rt > 1) rt = 1;
    else if (rt < -1) rt = -1;
    
    // Return:
    return { rotThrust:rt, aftThrust:thrust,userStore:userStore };
    



  • I don’t know, but I would’ve think so. Part of the reason is that almost no one actually learns to read this stuff fluently without using the key and going letter by letter. So getting any significant sample of people to test it on would probably be hard

    I can’t read (or write) it without the key, however I’m quite fast if I get to do it. I have thought of trying to learn it completely, mainly to see how hard it would be and what I’d learn (apart from, you know, learning brädgårdschiffer) from learning a “new” alfabet. I’d be interested to see how I view it in comparison to regular Latin script. I speak somewhere between 2 and 4 languages depending on how you count and I’ve found every new one interesting and insightful to learn so it would be fun to see if learning to read a new script fluently would be anywhere near as insightful. Ultimately I’d like to learn Korean or Chinese but that be a major challenge and take a lot of time (also, I could probably not squeeze it in to my formal education with the path I’m going to take so I’d have to do it in my free time)



  • Does one two one representations of the Latin alfabet count? In such case I’d mention a cipher used in Sweden called “brädgårdschiffer”. Here is “hej på dig!” written using brädgårdschiffer with my very sloppy writing on my phone:

    Hej på dig!

    It’s decrypted by matching up the shape and amount of dots with the letters in the key below. You look at the edges around the letters and the dots above that square.

    key for brädgårdschiffer. This image is broken (: Link

    I do however think that this chiffer probably exists outside of Sweden under some other name and other letters included (note that W and Q aren’t included in the key. They aren’t really used for in Swedish, apart from loans from other languages)




  • Hjalmar@feddit.nutoScience Memes@mander.xyzHmmm
    link
    fedilink
    English
    arrow-up
    1
    arrow-down
    4
    ·
    2 months ago

    Only the transformations one is correct. All the other ones seemingly also preform a translation, and even if they might be correct if you take the orgin to be slightly outside of the shape but that’s bad for educational purposes. Also this one makes the translation transformation look like the identity transformation.

    This last one might just be me, but shouldn’t shearing be included here?


  • I’m 15 years old and live in Europe. Almost all of my friends (and the stranger next to me on the train) use Snapchat. Personally I find it very annoying as my experience mainly consist of getting spammed with meaningless, completely irrelevant and utterly boring selfies by anyone I happen to add. And then, just to make things worse people find it inpolite not to answer with another selfie. And then it’s the chats that kinda work but the UI looks clutterd and half baked. Also messages disappear after a while which is utterly annoying.

    At least it would be kinda easy to find people on Snapchat (there’s no reason to ask around for someone’s number) if it wasn’t for the fact that people use the most random pseudonyms imaginable so it’s a pain just to know who is who, and almost impossible to pin down new people.

    Also I don’t give it location sharing permission, that shit is creepy as fuck, I don’t want everyone that I kind of vaguely know to know where I am all the time