why is my save not saving correctly??

  • wisco11
    6th June Member 0 Permalink

    in this save: id:3384209  the bcln is supposed to have a life of -1, i type this into the console, it sets it, i save it, i reload, and the life is 0. does anyone know how to fix this??

  • LBPHacker
    6th June Developer 1 Permalink
    There's no way to, negative life values cannot be saved.
  • wisco11
    6th June Member 0 Permalink

    really? they should add that.

    ok. i just set it to the upper integer limit.

    Edited once by wisco11. Last: 6th June
  • pacmanfan123
    6th June Member 0 Permalink

    @wisco11 (View Post) I think they might save negative life values in the official version 100 in TPT . But, I could be wrong .

  • LBPHacker
    6th June Developer 4 Permalink
    Nope. Hint: you don't have to reply if you have zero idea what you're talking about.
    Edited once by LBPHacker. Last: 6th June
  • ALumpOfPowderToy
    7th June Member 0 Permalink

    @LBPHacker (View Post)

     I do wonder why the life value doesn't wrap around back to 65535. That's what I'd expect from the int->unsinged short conversion during saving. Is there any reason why or is it just a random dev decision?

  • LBPHacker
    7th June Developer 0 Permalink
    Yeah it's a "random dev decision", it's clamped to be within [0, 0xFFFF]. I think we do have other fields that are saved by truncation like you'd expect.

    https://github.com/The-Powder-Toy/The-Powder-Toy/commit/aa2ec3d1624bb4dd88b276d8ada6aae8073571fc
    Edited 2 times by LBPHacker. Last: 7th June