Author Topic: How to separate the text and game physics in GAME.PRE file?  (Read 830 times)

Cas

  • Corkscrew Cad
  • ***
  • Posts: 1093
  • Think different. That's OK... as long as you think
    • View Profile
    • Dimioca Labs
Re: How to separate the text and game physics in GAME.PRE file?
« Reply #15 on: March 06, 2021, 02:55:51 AM »
That's right. You should only get corruption if you are directly overwriting the PRE file
Earth is my country. Science is my religion.

GTAMan18

  • Otto's Student
  • **
  • Posts: 329
    • View Profile
Re: How to separate the text and game physics in GAME.PRE file?
« Reply #16 on: March 06, 2021, 08:50:21 AM »
If you ask, I worked with Stressed all the time

Just to be sure: are you getting those text-related errors after editing GAME.PRE with Stressed and saving it as GAME.RES? If so, that's pretty strange, and should be investigated further. Stressed is supposed to take care of the lengths declared in the resource file header so that changes like those you are doing don't lead to memory being overwritten in wrong places.

Stressed can't open GAME.PRE, even after converted to GAME.RES, so I used a hex editor, which made the corruption
Tenyek focimdal 2005-tol 2013-ig

GTAMan18

  • Otto's Student
  • **
  • Posts: 329
    • View Profile
Re: How to separate the text and game physics in GAME.PRE file?
« Reply #17 on: March 06, 2021, 10:31:51 AM »
In GAME.RES the problem is, that Stressed can't open cinf and crak, which are very important segments. I think, that cinf stores the behavior of the obstacles, and the crak contains the cracked state.

And if I select ignore this resource, it'll screw up the physics, but at least, the car is drivable

Proof: https://youtu.be/XLuRz4Gu2sU
« Last Edit: March 06, 2021, 04:00:31 PM by GTAMan18 »
Tenyek focimdal 2005-tol 2013-ig

Duplode

  • Breaths Stunts
  • ******
  • Posts: 3948
  • Fear is your only god on the radio
    • View Profile
    • The Southern Cross Stunts Trophy
Re: How to separate the text and game physics in GAME.PRE file?
« Reply #18 on: March 06, 2021, 02:33:49 PM »
In GAME.RES the problem is, that Stressed can't open cinf and crak, which are very important files. I think, that cinf stores the behavior of the obstacles, and the crak contains the cracked state.

Okay, I think this solves the mystery. Stressed built from the most recent sources (which I and, IIRC, Cas use) can handle cinf and crak, but the 0.2.1 release (including the Windows binary linked to from Southern Cross) can't. Tomorrow I'll try to prepare an updated Windows executable, which in any case is long overdue.   

GTAMan18

  • Otto's Student
  • **
  • Posts: 329
    • View Profile
Re: How to separate the text and game physics in GAME.PRE file?
« Reply #19 on: March 06, 2021, 02:38:15 PM »
Thank you very much in advice!
Tenyek focimdal 2005-tol 2013-ig

GTAMan18

  • Otto's Student
  • **
  • Posts: 329
    • View Profile
Re: How to separate the text and game physics in GAME.PRE file?
« Reply #20 on: March 06, 2021, 06:11:40 PM »
Stressed built from the most recent sources

If you're planning to update its resource code, then make sure to add these to
stressed/resources/conf/defaults.conf

pbox = tuning
ter0 = tuning
ter1 = tuning
ter2 = tuning
ter3 = tuning
ter4 = tuning

Because the terrains, and the pbox (The list you can select track elements from during editing with the in-game editor) are actually tuning values

I'm not sure about mnam, snam, and tnam, but I imported them as text, and after saving, the saved TEDIT.RES worked, however I needed to duplicate the terrain segments in order to make them work correctly, but ter4 is replaced with ter1 by me in the Hungarian translation, because the ter4 segment was duplicated however, but remain corrupted
« Last Edit: March 06, 2021, 06:14:03 PM by GTAMan18 »
Tenyek focimdal 2005-tol 2013-ig