AGS 4.0 - Early Alpha 9 for public test

Started by Crimson Wizard, Thu 01/06/2023 14:00:59

Previous topic - Next topic

Crimson Wizard

Quote from: Baguettator on Sun 24/03/2024 21:27:40The scripts seem to be .crm files, but they are at the root of the game's folder (with othr scripts)

No, .crm files are compiled rooms. Room scripts must be called roomN.asc and located inside "Rooms".
From your post it seems like they are not there.

Do you have a previous version of the game backed up? Does it have roomN.asc files? If so, could you try upgrading once more from backup copy, and see if room scripts appear properly in ags4 version?

eri0o

In the Rooms directory, if I remember correctly, there is a directory with a number for each room and in each directory a XML for the room description, a script Room1.asc (or whatever is the room number)  a few PNG files for the masks and background.

The crm files in the project root are just the "built" binary rooms, and in ags4 you don't need to version them anymore because it should be possible to recover them from the source files in Rooms directory.

Edit: CW was faster. :)

Baguettator

Ahah, thanks a lot for your answers (and congrats to CW the man who answers faster than his shadow !)

I don't see any .asc file in the room folder, but there were .asc files for each of my rooms in the 3.6 version of my game. I could try to re-upgrade my game from a backup version, but it's exactly what I did before, so it should be the same result...

Perhaps I could try to copy/paste manually the .asc files from my back up directly into rooms folder in the upgraded version ?

I will try to reupgrade too and tell you if it worked (it's an other pc where I can't go often, but perhaps in the evening today)

Crimson Wizard

Quote from: Baguettator on Mon 25/03/2024 04:25:06Perhaps I could try to copy/paste manually the .asc files from my back up directly into rooms folder in the upgraded version ?

Yes, you could do that too.

Baguettator

Copy/paste the .asc files from the back up seems to work. but upgrading deletes the asc files... Could it be fixed ?

Crimson Wizard

Quote from: Baguettator on Mon 25/03/2024 08:42:08Copy/paste the .asc files from the back up seems to work. but upgrading deletes the asc files... Could it be fixed ?

I never experienced such problem when testing upgrading a project.
Which exact version of AGS 4 are you using? (this may be seen in Help->About)
Does this happen to any project you upgrade or only to a particular one?

room.asc is the only file that is moved to Rooms. *.crm files are not moved, and the rest is created anew. In theory this might mean that file copying or moving is not working for some reason. It may be worth investigating if this process is safe, in terms of checking wether copy operation is successful before removing old files.

Do you have any antivirus, or programs like Windows Defender active on your computer? If so, would it improve the situation if you disable them, or tell them to ignore your project folder before upgrading?

Alan v.Drake

#66
When I asked when it crashed, I meant the Editor, because it's possible something went wrong during upgrade and the upgraded project was never saved (you have to save manually in any case). If the project is recognized as "not upgraded" the Editor will retry again to upgrade from the CRM files, but this time there wont be the scripts, and this is how these problems arise.

We should probably force a save after an upgrade, or ask for confirmation before proceeding.

- Alan

Crimson Wizard

Quote from: Alan v.Drake on Mon 25/03/2024 11:00:06If the project is recognized as "not upgraded" the Editor will retry again to upgrade from the CRM files, but this time there wont be the scripts, and this is how these problems arise.

We should probably force a save after an upgrade, or ask for confirmation before proceeding.

I wrote a ticket about this problem in the past:
https://github.com/adventuregamestudio/ags/issues/1596

Not sure if it's the same case though, as this problem occurs only if you close the Editor without saving nor building (or running) the game after upgrade.

Baguettator

That's exactly what I did : I openned my game with AGS4.0, it converted the rooms, but I didn't save the project with AGS 4.0 the first time. So the .asc files were deleted at the second launch of AGS4.0 as Alan v.Drake just said. Sorry, it was my fault  :-[

I will try to upgrade fully my game soon, and will tell you if I encounter any bug !

Thanks a lot for helping !

Baguettator

Hey again, sorry for asking again, but will AGS 4.0 be able to manage PNG files in Dynamic Sprites ? It would be so great especially for transparent backgrounds...

Crimson Wizard

#70
Quote from: Baguettator on Thu 28/03/2024 11:58:47Hey again, sorry for asking again, but will AGS 4.0 be able to manage PNG files in Dynamic Sprites ? It would be so great especially for transparent backgrounds...

If you are referring to DynamicSprite.CreateFromFile, then I suppose it's possible to extend the supported formats, if we add a proper image-loading library to the engine (this was discussed some time ago).

But which "transparent backgrounds" are you speaking of, and why do you need dynamic sprites for these?

Baguettator

Well, using PNG files will be always easier, this way you don't need to save a BMP file in a "magic pink" background to "emulate" a transparent background. It would be a quality-of-life improvement I presume ?

EDIT : also, I'm always working with PNG files, never with BMP files. But perhaps I'm a lonely bad guy :)

Anyway, the proposal milestone of AGS 4 looks great ! Have you got any release date for a fully achieved version ?

Crimson Wizard

Quote from: Baguettator on Sun 21/04/2024 14:04:36Well, using PNG files will be always easier, this way you don't need to save a BMP file in a "magic pink" background to "emulate" a transparent background. It would be a quality-of-life improvement I presume ?

EDIT : also, I'm always working with PNG files, never with BMP files. But perhaps I'm a lonely bad guy :)

Everyone seems to be working with PNGs today, and AGS allows to import PNGs into your game.
It's just that creating dynamic sprites from image files is not a very common thing, so extending image format support for this function was never addressed.

Baguettator

Well at least for me, creating Dynamic Sprites using PNG files could be very useful :)

SMF spam blocked by CleanTalk