• Valmond@lemmy.world
    link
    fedilink
    English
    arrow-up
    34
    arrow-down
    2
    ·
    7 hours ago

    try writing it it in Assembly

    Small error, game crashes and takes whole PC with it burning a hole in the ground.

    • ayyy@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      37
      ·
      6 hours ago

      The game Roller Coaster Tycoon was famously hand written in raw CPU instructions (called assembly language). It’s only one step removed from writing literal ones and zeros. Normally computers are programmed using a human-friendly language which is then “compiled” into CPU instructions so that the humans don’t have to deal with the tedium and complication of writing CPU instructions.

  • Wilzax@lemmy.world
    link
    fedilink
    English
    arrow-up
    86
    arrow-down
    3
    ·
    10 hours ago

    Your game will actually likely be more efficient if written in C. The gcc compiler has become ridiculously optimized and probably knows more tricks than you do.

    • dejected_warp_core@lemmy.world
      link
      fedilink
      English
      arrow-up
      25
      ·
      8 hours ago

      Especially these days. Current-gen x86 architecture has all kinds of insane optimizations and special instruction sets that the Pentium I never had (e.g. SSE). You really do need a higher-level compiler at your back to make the most of it these days. And even then, there are cases where you have to resort to inline ASM or processor-specific intrinsics to optimize to the level that Roller Coaster Tycoon is/was. (original system specs)

      • Wilzax@lemmy.world
        link
        fedilink
        English
        arrow-up
        5
        ·
        3 hours ago

        If you’re writing sloppy C code your assembly code probably won’t work either

    • s_s@lemm.ee
      link
      fedilink
      English
      arrow-up
      2
      arrow-down
      4
      ·
      7 hours ago

      Write it in Rust, and it’ll never even leak memory.

  • einlander@lemmy.world
    link
    fedilink
    English
    arrow-up
    60
    arrow-down
    2
    ·
    7 hours ago
    • Programming was never meant to be abstract so far from the hardware.
    • 640k is enough ram for everybody.
    • The come with names like rust, typescript, go, and python. Names thought up by imbeciles.
    • Dev environments, environmental variables, build and make scripts, and macros, from the minds of the utter deranged.

    They have played us for fools

  • UnderpantsWeevil@lemmy.world
    link
    fedilink
    English
    arrow-up
    47
    arrow-down
    1
    ·
    11 hours ago

    Step 1: Begin writing in Assembly

    Step 2: Write C

    Step 3: Use C to write C#

    Step 4: Implement Unity

    Step 5: Write your game

    Step 6: ???

    Step 7: Profit

  • lugal@lemmy.world
    link
    fedilink
    English
    arrow-up
    102
    ·
    11 hours ago

    I don’t know if everyone gets the reference: RollerCoaster Tycoon is in fact writing mostly in assembly to use the hardware more efficiently

    • Lem Jukes@lemm.ee
      link
      fedilink
      English
      arrow-up
      48
      arrow-down
      3
      ·
      10 hours ago

      It also makes it really portable which is a big part of why all the ports to modern systems are so close to the original. Obligatory OpenRCT2 shoutout.

      • Faresh@lemmy.ml
        link
        fedilink
        English
        arrow-up
        13
        arrow-down
        1
        ·
        edit-2
        6 hours ago

        Writing it in assembly would make it pretty much the opposite of portable (not accounting for emulation), since you are directly giving instructions to a specific hardware and OS.

        • Lem Jukes@lemm.ee
          link
          fedilink
          English
          arrow-up
          2
          arrow-down
          1
          ·
          2 hours ago

          Not necessarily, unless you’re working on something like an OS you’re not usually directly accessing/working on the hardware. As long as you can connect the asm up to your os/driver abstraction layer and the os to hardware apis work the game should be functional. Not to mention RCT targets the x86 assembler architecture which was one of the most popular at the time

  • JoYo@lemmy.ml
    link
    fedilink
    English
    arrow-up
    1
    ·
    10 hours ago

    you need all of that when writing a game in assembly. wtf do you think assembly is?

  • mtchristo@lemm.ee
    link
    fedilink
    English
    arrow-up
    54
    arrow-down
    2
    ·
    7 hours ago

    Roller coaster Tycoon is one of a lifetime game.

    Now everything is electron or react shit. Gone are the times of downloading fully featured software under 10mb.

      • otp@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        12
        arrow-down
        2
        ·
        4 hours ago

        Probably not as optimized though.

        RCT could run on a toaster from the 90’s (ok, maybe early 2000’s) and looked amazing for the time.

        OpenRCT can run on a toaster from the 2010’s and looks great because of the timeless art style of the original.

        It’s still an incredible feat, though!

  • Gork@lemm.ee
    link
    fedilink
    English
    arrow-up
    23
    ·
    11 hours ago

    Shifts bit to the left

    Um what am I doing

    Shifts bit to the right

    program crashes