Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Crimson Wizard

#381
Quote from: Eon_Star on Fri 02/06/2023 22:12:38I tested this version. When in room editing window the background PNG was not visible (Gray Background). In the game window however it was ok. Thanks for your efforts.

Hello, this is a known issue that I'm currently looking at. The background does not actually become grey, it becomes fully transparent with alpha channel = 0. It's visible in the game because the engine forces room bgs to be rendered opaque.

The workaround currently is either to reimport background from the original source, or to open a bg png in the Rooms dir and fill alpha channel with opaqueness (if you graphic editor allows that).
#382
Well, if it's restricted to one finger/button, then personally I'd vote for 1-click style. People seem to be conflicted about verb coin style. 1-click + hotspot description either around cursor or at the fixed position on screen makes a easy combination.
#383
Quote from: cat on Fri 02/06/2023 12:47:06I would have never guessed this is a possible thing on a phone. Some people already don't get that they can right click with the mouse when using a BASS UI, I doubt anyone will understand this on a touch device.

If the problem is guessing, then displaying a simple tutorial on screen as the game starts in the first room may be enough.

After all, there are games with more complex controls (using keyboard or gamepads), and people learn to use these, so why cannot they learn using right click in adventure game? This is somewhat baffling.

EDIT: I might add, it's possible to design slightly different controls for desktop/mobile, using System.OS as a condition.
#384
Quote from: cat on Thu 01/06/2023 16:03:34Oh, btw, what is the targeted AGS version? 3.6.0 I assume?

I believe that 3.6.0 should be minimal, at least because it supports Unicode, and can build to web/android from the Editor.
3.6.1 is in beta stage, it seems relatively stable, but who knows... Anyway, it will be possible to load 3.6.0 game sources into next 3.6.* updates if they come out later.

I think it should go without saying that the game must not use any backwards compatibility settings, or deprecated script API.

Quote from: cat on Fri 02/06/2023 11:58:38Thinking further about UI: With web port and Android port, I think the UI should be one that is usable on touch. This excludes BASS and Sierra.

Our touch screen emulation supports 2-finger mode, where tapping second finger while holding first acts as a right click.

The SCUMM style is complicated for the contemporary times. The template itself is additionally complex, with extra utilities, although it might be possible to reimplement a simpler variant without anything extra.

If you want to constraint to 1-finger/button controls, then it's either 1-click style, or verb coin and any variants of verb coin (with context menu of sorts) either with hold + drag + release or tap on object + choose verb from context menu method.
#385
KNOWN ISSUES

[FIXED]1. Some room backgrounds may become fully transparent after the project import. Their RGB colors persist, but alpha channel becomes 0 in every pixel.
The workaround currently is either to reimport background from the original source, or to open a bg png in the Rooms dir and fill alpha channel with opaqueness (if you graphic editor allows that).



2. There are couple of functions which now have less arguments compared to the previous versions of AGS.

These functions are:
- DynamicSprite.Create and DynamicSprite.CreateFromExisting, they no longer have "has alpha" argument, as in 32-bit games all sprites are considered to have usable alpha channel now. (This is actually under question, and may change again to e.g. have an argument that defines a pixel format)
- Overlay.CreateGraphical does not have "transparent" arg, as it was useless all the way.

This is an unusual case (commonly arguments are added). This may cause script errors if you import a project or a module.

The solution for a quick fix, when you don't want to manually fix all these function calls in your game, is to create a script module on the top of the scripts list, and place helper extenders there which wrap actual function calls, like this:

Code: ags
DynamicSprite* Create(static DynamicSprite, int width, int height, bool unused)
{
    return DynamicSprite.Create(width, height);
}

static DynamicSprite* DynamicSprite.CreateFromExistingSprite(int slot, bool unused)
{
    return DynamicSprite.CreateFromExistingSprite(slot);
}

Overlay* CreateGraphical(static Overlay, int x, int y, int slot, bool unused, bool clone)
{
    return Overlay.CreateGraphical(x, y, slot, clone);
}

Overlay* CreateRoomGraphical(static Overlay, int x, int y, int slot, bool unused, bool clone)
{
    return Overlay.CreateRoomGraphical(x, y, slot, clone);
}
#386
AGS 4 - Early Alpha 4
Full release number: 4.0.0.1

ACHTUNG!

This is a EARLY ALPHA version of AGS 4.
This is a WIP version, and must go through extensive testing.
Use at your own risk. Please back up any games before opening them in this version of AGS.
New settings in this version WILL make your project files unusable in previous versions after saving with this version.


For Engine/Editor developers
Spoiler


Last updated: 3rd November 2023



This release is brought to you by:

- Alan v.Drake
- Crimson Wizard
- eri0o (joystick & gamepad support, other improvements)
- fernewelten (new script compiler)
- ChamberOfFear, aka persn (open room format, Editor improvements)
-  Matteo Piovanelli (some improvements)



What is AGS 4

AGS 4.0 is an upcoming version which is currently in experimental stage. The primary idea of this version is a complete removal of the deprecated functionality: game settings and script functions. AGS 4 will no longer be able to run older 2.* or 3.* games. It will only guarantee the import of the latest 3.* game projects (such as 3.6.0). This means that if you want to update your existing game to AGS 4, then you'll have to first import and save it in 3.6.0. If your game is using any of the deprecated settings or script commands - you'll have to replace these, as 4.0 will no longer have necessary "backwards compatibility" switches in General Settings.

It is still in works, and there is a number of large changes planned.
But what are the ready major new features of AGS 4?

Open Room format

The new room format made by @ChamberOfFear now stores rooms as a collection of directories with room data split into multiple files. The room properties are stored in XML, which make it possible to read and even edit by hand outside of the editor. Room backgrounds and region masks are stored as separate PNG images.

This improves the safety of working with rooms, allows to change things externally, and simplify teamwork to some degree.

New script compiler with new syntax features

The new compiler was written by @fernewelten, and it grants a whole bunch of syntax improvements to the AGS script, such as nested structs, multi-dimensional arrays, dynamic arrays have `Length` pseudo-property, and so on.

The full cheat-sheet of the new features may be found here:
https://github.com/adventuregamestudio/ags/wiki/New-compiler%27s-end-user-cheat-sheet
If anyone is curious, here's the more "technical" version, explaining things in depth:
https://github.com/adventuregamestudio/ags/wiki/Features-of-the-new-Script-Compiler

Managed pointers inside managed structs

These are also allowed now (this is not related directly to the script compiler, but also to how engine handles dynamically created objects). This feature finally opens full potential of structs referencing each other with pointers, and allow you to create virtually any kind of data storage in script.

To give an example:
Code: ags
managed struct Item; // pre-declaration

managed struct Person {
    Item* items[];
};

managed struct Item {
    Person* owner;
};

Here's a LinkedList module I wrote for a test:
https://www.dropbox.com/s/sxur2bsccsvaqmr/ags399-LinkedList.zip?dl=0

Advanced object features

The game objects have two new features worth mentioning up front: Blend Mode and Rotation.
* BlendMode property lets you change the way object is drawn, selecting one of the 10 classic modes (Add, Subtract, Dodge, etc). This gives you ability to make more visual effects in your game.
* Rotation property (called GraphicRotation in some) lets you to rotate the object by a number of degrees. Most standard things have this, and even Cameras, so you may, for example, rotate the whole room view, and characters in it individually. Rotation is hardware accelerated (in Direct3D/OpenGL mode) and does not slow things down, unlike rotating dynamic sprites. Engine correctly detects clicks on rotated objects, so for example, rotated GUI will be fully functional.

What else is PLANNED for AGS 4?

Here's the milestone proposal:
https://github.com/adventuregamestudio/ags/issues/1298

It's not clear at the moment whether all of these features will be a part of the first 4.0 release, but at least some of these will hopefully be.

How safe is this WIP version currently?

It is relatively stable, and there are few people who were already using it to make games for a while: Alan Drake is one of them, and I suspect that fernewelten was also using it sometimes for his games because of his new compiler (but I may be mistaken).
The biggest problem with this is that this version will be updated further, so some things may not be final. Project format may also change in the next updates. We'll try to keep things upgradeable (so that the previous projects made in this WIP version won't just break).
And it surely it will benefit from more testers.



The full changelog follows:

Contains all additions from AGS 3.6.1 Beta 8, except ones made for backwards compatibility.

Common:
- Most of the deprecated functionality (game settings and script API) is cut out from both Editor and Engine, and is no longer supported. The Editor guarantees to import the projects saved by AGS 3.6.0 and later. The Engine may run games compiled in 3.6.0, but only so long as they don't use any deprecated settings or script commands.
- Completely removed Global Messages and Room Messages.
- Removed built-in support for Game Score, including related game settings and GiveScore script command. Users are advised to script their own score counter if they need one.
- Removed support for '[' as a linebreak character in text.
- Added FLAC support for music, speech and sound effects.

Editor:
- Open room project format: rooms are now saved as subfolders in "Rooms" folder, where each component has its own separate file (room data, backgrounds, masks and scripts).
- Support room backgrounds and masks as PNGs.
- Translation sources are now saved in PO format.
- General panel look enhancements.
- Support built-in Base Color Themes that have the custom themes applied over them.
- Game template selection now displays template's description right in the dialog.
- F2 is now a hotkey for editing labels in the Project Tree. "Game statistics" are now displayed by Ctrl + F2.
- Script editor supports "word wrap" mode.
- In General Settings added "Use extended compiler" option that lets to choose a new script compiler for your game (see list of changes in related section below).
- Added BlendMode property to Characters, GUI and Room Objects.
- Added readonly Length property to AudioClips, for the reference.
- Fixed faulty double-click on project items in case user dragged the cursor away.

Compiler:
- The new extended script compiler is available. Almost all of the new Scripting features are only supported when using the new script compiler.
- Optimization to the bytecode generation: same scripts may now work faster at runtime.

Scripting:
- Support for having regular structs inside any structs (regular or managed); there's no nesting limit.
- Support having managed pointers inside managed structs.
- When declaring a pointer to managed struct you may now omit "*" sign.
- When writing struct's function's code you may now omit "this" keyword when addressing current struct's member (variable, attribute or function).
- Support for extender attributes.
- Support for multi-dimensional regular (non-dynamic) arrays. They may have any positive number of dimensions.
- Dynamic arrays now have Length pseudo-attribute used to retrieve their length.
- Global variables may now be declared right after struct's or enum's declaration, between the closing bracket and closing semi-colon.
- Functions now may call any other function from within same script, regardless of their order of declaration.
- Compiler can now evaluate integer or float expressions at compile time whenever result is actually constant and can be calculated at compile time.
- "const" keyword now may be used to define compile-time "int" and "float" constants.
- "readonly" keyword now may be used to declare non-modifiable variables (local or global) and function parameters.
- Added "fallthrough" keyword, which is used to hint that switch's case does not require a break statement. This is only to clarify coder's intent and prevent compiler's warnings.
- Support pre-increment and pre-decrement operators (++x, --x).
- Support bitwise negation operator (~x).
- Support addressing members of the function return values in one expression. This lets chain multiple commands including function calls, e.g. GetObject().MyVariable...and so on.
- Two sequenced string literals ("text" "text") are now automatically concatenated.

Script API:
- Most of the deprecated API is now removed completely, except those that have no equivalent.
- Added SCRIPT_EXT_AGS4 macro which tells whether extended script syntax is supported by the compiler. This may be used to know whether the script is being compiled by the old or new compiler.
- Added SCRIPT_EXT_NESTEDPOINTERS macro which tells whether nested managed structs are supported by the compiler.
- Added Joystick struct, meant to work with joystics and gamepads in script.
- Added BlendMode enum.
- Added Character.BlendMode, GUI.BlendMode, Object.BlendMode, Overlay.BlendMode.
- Added Character.UseRegionTint and Object.UseRegionTint, deprecated Character.IgnoreLighting.
- Added Camera.Rotation, Character.GraphicRotation, GUI.Rotation, Object.GraphicRotation, Overlay.Rotation.
- Added DrawingSurface.BlendImage() and DrawingSurface.BlendSurface() functions.
- AudioChannel.Position and PositionMs no longer return a very large value while skipping cutscene.
- Removed "hasAlphaChannel" param from DynamicSprite.Create() and CreateFromExistingSprite().
- Removed HasAlphaChannel property from DialogOptionsRenderingInfo.
- Removed "transparent" param from Overlay.CreateGraphical() and CreateRoomGraphical().

Engine:
- Support joystick and gamepad input.
- Implemented more accurate Character movement. The movement direction is now more precise and diagonal movement speed no longer may exceed MovementSpeed setting.
- Animated buttons now display flipped frames correctly.
- (possibly) Fixed characters sometimes keep walking animation for a short time after arriving to their destination.
- Added "--print-rtti" command line option which prints script RTTI table to the log.
  (RTTI stands for "runtime type information", and is used for handling of certain advanced script features, such as nested managed structs.)

#387
Quote from: RootBound on Thu 01/06/2023 12:13:46Does this sound like an accurate summary of the consensus here?

Yes, I fully support the above.
#388
Quote from: RootBound on Thu 01/06/2023 11:44:21I don't know how to post the text or where in the AGS manual it should go. If someone can tell me the proper place and how to add it, I will put the text there so that others can edit or expand upon it.

I created a placeholder page here:
https://github.com/adventuregamestudio/ags-manual/wiki/InventoryItems

Added a section of "Game Features" on the main page:
https://github.com/adventuregamestudio/ags-manual/wiki#game-features

More pages may be added likewise.

I was not certain whether place "Game Features" before or after the "Editor" section, but that may be adjusted later.
#389
There are Global Variables for this purpose, you may find them in the Project explorer, and add as many as you need.
https://adventuregamestudio.github.io/ags-manual/GlobalVariables.html
#390
Well, if you set index to -1, then you cannot use it on array. So the solution is to check whether something is selected before trying to get CurrentContact.

Code: ags
String CurrentContact;
if (Listbox_Contacts.SelectedIndex >= 0)
{
    CurrentContact = Listbox_Contacts.Items[Listbox_Contacts.SelectedIndex];
}

if(CurrentContact != null && CurrentContact=="Contact1")
{
    gContactGUI.Visible=true;
}
#391
Quote from: The creature on Wed 31/05/2023 16:50:39If I set the selectedIndex to -1 (like it says in the manual) it works. But, in a repeatedly executed I'm selecting items via string names and when I do this I get a compile error

Please post your code and tell what the error is?
#392
Quote from: Babar on Tue 30/05/2023 19:27:19No reason to not have all of them, adjustable through the settings.
And by "all" I mean the ones trivially available through the templates (Sierra, LucasArts verblist, verbcoin, 2 click/bass)

In addition to what Snarky sais above, I can name a reason to not have them all: these control methods imply different amount of verbs. This means that you will inevitably have to script the gameplay to require only minimal amount of verbs for walkthrough, and as a consequence that would make the rest of the verbs (and hence the control styles) redundant.


Quote from: cat on Tue 30/05/2023 19:35:31The only difficulty is to make is clear in code what belongs to which interface. rep_ex and mouse_click would have to be huge if else blocks, clearly separating the logic of each individual interface type.

That problem on its own may be solved by having control styles in separate script modules, as rep_ex, mouse_click and so on may be repeated as many times as needed in the game. You will only have to have a global variable, used to test which is the active style.
#393
This is fine overall. Personally I have a concern about the general "scientific tone", but I don't know if it's just me. I would not want to seem like nagging over this.

Perhaps if some other AGS users could comment on this too?...

On the other hand, you could begin adding the texts to the manual source, and somebody might adjust the style later.



To elaborate, by "scientific tone" I mean the expressions like: "An inventory item's main capabilities include the following: " and then "being added", "being removed", "becoming active". This may be just me, but it feels like reading an algebra textbook.

I might give a link to the Tutorial we already have in our manual, which maybe could serve an example of a "tone":
https://github.com/adventuregamestudio/ags-manual/wiki/acintro1
https://github.com/adventuregamestudio/ags-manual/wiki/acintro2
https://github.com/adventuregamestudio/ags-manual/wiki/acintro3


For an alternate variant, I might imagine a more vivid text style (roughly):

QuoteInventory item has:
* unique script name, used to refer to this item in scripts;
* textual name, for describing it to player;
* graphic, for displaying it on screen;
* cursor graphic, for setting a cursor when the item is selected.

What can you do with inventory item?
* Add to character's inventory and remove from one;
* Make item "active", which means it is "selected" for use;
* Use active item on other game entities, such as hotspots, room objects, ..... ......
* Whole inventory may be displayed on a GUI using InventoryWindow control. This is a standard way of displaying items on screen, but there are others (see below).

Each of the above points may be expanded below, with references to both editor and script commands: how do you do this and that with an item, how do you change their properties, etc.

Then this may be continued further, explaining the alternate ways of displaying and using items in game.

(very roughly)
QuoteItems do not have to be visible, they may be used even as a logical list of things.
.....
You may display items as a textual list, by using ListBox and filling it with Inventory Item's names.
.....
You may script your own custom inventory window using item graphics. For instance, you may place buttons on GUI and assign Inventory item's Graphic property as a button's NormalGraphic to make it look like an item is placed there.
#394
Quote from: Snarky on Fri 02/12/2022 09:07:02-First, even when "Allow relative asset resolutions" is disabled, the property is available in the sprite editor and can be modified. This is confusing because changing the value has no actual effect in-game. I think the property should be hidden or made non-editable when the game-wide setting is disabled.

I believe it's possible to do (similar thing is done for a few other properties in game).

Quote from: Snarky on Fri 02/12/2022 09:07:02-Second, it used to be possible to bulk-edit this setting by selecting multiple sprites and adjusting the property. Now, the changed value is not applied to all the selected sprites, but only to the first one. I would consider this a regression.

I did not pay attention to this earlier, but this was actually a thing at least in AGS 3.2.1. It was possible to select multiple sprites, and the property grid would display only matching property values, while blanking out mismatching ones.
Back in a day the sprite resolution was the only property that could be changed, now alot of import settings may be changed.
EDIT: this is no longer working since AGS 3.5.0, where the sprite import was reimplemented.

Opened an issue: https://github.com/adventuregamestudio/ags/issues/2008

Quote from: Snarky on Fri 02/12/2022 09:07:02Separately from this, I think it would be nice if the ability to pre-scale sprites was reintroduced in a more straightforward way, e.g. a sprite scaling setting that could be set to 1x, 2x, 3x, 4x.

I guess letting to set fully arbitrary width & height could be also an option; but the question will be whether this is a import setting or a runtime effect. If it's a runtime effect, then the engine should probably precreate a scaled sprite on load in software render mode, or apply this extra scaling in accelerated render mode (d3d,opengl etc).

I further guess this is something to consider for ags4.
#395
Quote from: jumpjack on Thu 19/01/2023 08:23:25Is this the only thread about AGS4? It is very old.
The only other one mentioning AGS4 is Engine & Editor V4.0 Alpha - Proposal, and an issue on github.

I would like to follow the ongoing discussion, if any, about new features going to be implemented  in AGS4.

I add here a link to all AGS4-tagged issues on github, for reference:

Open
Closed



Yes, as ags4 branch gets more new major features, we should probably open a proper forum thread, explaining priority goals and current state.

The mentioned github issue "AGS 4.0.0 Milestone proposal" is probably most up-to-date ticket with goals.

The changelog describing new features may always be found here: https://github.com/adventuregamestudio/ags/blob/ags4/Changes.txt

The downloads may be found on our build server, if you find the latest entry mentioning "ags4" branch:
https://cirrus-ci.com/github/adventuregamestudio/ags/ags4

It's worth mentioning that the idea of what "AGS 4" is have changed over time. Originally (number of years ago) I had thoughts about more major overwrite there, but as time went, it became clear that we don't have enough workforce to handle any kind of overhaul. So currently the idea is to implement major changes in smaller steps, and allow to break backwards compatibility whenever it gets in the way.

The principle about compatibility is to guarantee support only for importing the latest 3.* project format (3.6.0 currently), but don't guarantee running games compiled with latest 3.*. In other words, AGS 4 should be able to transfer the 3.6.0 project, but earlier projects will have to be upgraded to 3.6.0 first.
#396
Quote from: edmundito on Sat 27/05/2023 14:50:56My specs are:
Windows 10 Home 21H2
Resolution: 2880x1800
Scale: 200%


So it has these glitches on a particular monitor only, or overall on Win 10? Or do you have only 1 monitor (i was not sure how to interpret what you say)?
#397
Quote from: edmundito on Sat 27/05/2023 14:35:40I tested the editor on my high DPI display, and many panels must be fixed. I also wonder if Editor plugins would also be affected.

I made a video showing the glitches: https://1drv.ms/v/s!Ap-i3SuJykLihinGCZ0jdiCcj6E_?e=eBEiVC

Edit: I just tested the Speech Center editor plugin, and there are problems: https://1drv.ms/i/s!Ap-i3SuJykLihituN9TEAgr3nvmj?e=XQgu9p

Could you demonstrate how the previous version looks on the same monitor?
Also, which OS do you run this on?

Personally I did not know how this works, as I have only 1 monitor and still using Windows 7...
EDIT: I might experiment with the Windows 10 vm later if I figure out how to emulate a very big monitor.

We might revert this change if there's no easy fix to this.
#400
AGS 3.6.1 - Beta 12
Full release number: 3.6.1.11

ACHTUNG!
This is a BETA version of AGS 3.6.1.
It's considered relatively stable but is not thoroughly tested yet and also may have planned additions.
Use at your own risk. Please back up any games before opening them in this version of AGS.
New settings in this version may make your project files unusable in previous versions after saving with this version.


For Editor
Spoiler

For Android
Spoiler
NOTE: the Editor now includes Android build component letting you prepare your own games for Android
[close]

For Engine/Editor developers
Spoiler


Released: 3rd November 2023

Previous stable version: AGS 3.6.0 P6 forum thread


This release is brought to you by:

- Crimson Wizard
- eri0o (Log Panel, Room panning, other additions)
- Walter Agazzi (fixes)



What is new in 3.6.1

3.6.1 is planned to be a minor version, focusing on improving performance and usability of existing features, and also possibly on restoring few functionalities cut while porting the engine to SDL2.

Common features:
- Implemented Deflate compression option for sprites. (This is an algorithm used in PNG and ZIP formats, and testing shows about x1.5-x2 compression improvement compared to LZW).

Editor:
- Discontinued Source control integration functionality, removed "Put sound and sprite files in source control" option from General Settings.
- Made Editor a Dpi-aware application, which might improve its looks in Windows 10 and higher. This is disabled (may be temporarily), as it turned out to cause troubles on some user setups.
- Improved Room Editor controls:
  Added free panning mode done by holding the middle mouse button, or alternatively - by holding Space + LMB.
  Mouse Wheel without key modifiers scrolls the room vertically; Shift + Mouse Wheel scrolls
  the room horizontally.
  Zoom is done by Ctrl + Mouse Wheel and room now zooms towards or outwards the cursor position.
- In Room Editor the context menu is now displayed by RMB or Shift + RMB while editing masks.
  The individual room mode menu is merged with the "copy coordinates" command when shown.
- In Dialog Script editor support most Edit menu and context menu commands from the regular Script editor, with a few exceptions.
- In Sprite Manager added command "View" -> "Show filenames" which toggles display of a sprite's source filename under the sprites.
- During sprite export Editor will display a proper progress dialog.
- Zoom controls in Character and View panes now allow downscaling too. View editor displays the preview sprite stretched to fill the parent panel.
- View editor now allows to select multiple frames at once, across multiple loops too, using standard Shift + LMB and Ctrl + LMB combinations. Properties panel lets modify properties for all the selected frames at once.
- Added "Replace with all sprites from folder" command to the View editor's context menu.
- For Audio Clips in the project tree added "Force Reimport", "Force reimport all file(s)" and "Replace Source File" context menu commands.
- For Output Panel added "Copy selection" context menu command.
- Implemented Log Panel that lets you see the engine and game logs right in the Editor.
- Improved LipSync panel looks in case user's system has display scaling option enabled.
- "Goto Definition" command in script will now work for most of the game entities too, such as Characters, GUIs, and so forth. In that case it will find a game's entity and open a respective editor panel for it. This still does not work for some types, such as Room objects, and Views.
- Added main menu commands for opening a Project folder and Compiled folder.
- Added "Export Global Messages to script" menu command. This command is meant for upgraded pre-3.2 game projects, and will generate a script with a String array, moving global messages texts there.
- For script's tabs added a context menu command for opening this script's location.
- In General Settings moved few properties to different groups for better consistency.
- Added "Scale Character sprite offsets" property to General Settings. This property refers to scaling of Character.z and sprite offsets added by LockViewOffset script command.
- Added TextureCacheSize and SoundCacheSize properties to Default Setup. These let configure the sizes of runtime texture and sound cache sizes respectively.
- Added "Leave room after fade-out" event to Rooms (script function called "Unload" by default).
- Added Translated property to all GUI Controls (was available only in ListBox). Translated property tells whether this control's text has to be translated, and applied text direction (in right-to-left text mode).
- Support '\n' linebreak character in the Label's Text and potentially other text properties.
- Config will now be saved in UTF-8, letting to support setup program's title text in unicode.
- Made Editor be somewhat more tolerate to missing XML nodes in Game.agf, in many cases it will still let open a game.
- When upgrading older game projects, Editor will insert a call to SetRestartPoint() in the end of the 'game_start' function in GlobalScript.asc. This is done to complement removal of an automatic restart point in the engine. This inserted command is safe to remove.
- When upgrading pre-3.2 rooms with disabled SaveLoadEnabled property the Editor will reset this property and insert a comment with a warning into the corresponding room's script. This is done because this property is deprecated as is no longer accessible.
- Export Game's Title into translations.
- Fixed Editor refusing to open a game if one of the translation files is missing.
- Fixed Project Explorer's folders collapsing after certain user actions, such as dragging items or renaming things.
- Fixed Editor could miss some of the files when cleaning up old compiled files after the Game's Filename property is changed.

Scripting:
- Support "#else" preprocessor directive.

Script API:
- Implemented Room's "After fade-out" event.
- Added eEventLeaveRoomAfterFadeout event for the global "on_event".
- Added eEventGameSaved event which runs after game was saved.
- Expanded interaction functions for Character, Object, InventoryItem, Hotspot and Region types: now they all receive respective object's pointer as a parameter, similar to GUI event functions, as well as a cursor mode this interaction was run with, if applicable.
- Added Game.ResetDoOnceOnly(), which completely resets all DoOnceOnly instances.
- Added ScriptName property to AudioClip, Character, Dialog, GUI, GUIObject, Hotspot, InventoryItem, Object.
- Added static GetByName() function to AudioClip, Character, Dialog, GUI, GUIObject, Hotspot, InventoryItem, Object.
- Added Object.AnimationVolume property, which works similar to Character.AnimationVolume.
- Added static File.ResolvePath() and File.Path attribute.
- Added support for a text formatting to a number of functions: DisplayAtY(), Character.SayAt(), Character.SayBackground(), DrawingSurface.DrawStringWrapped().

Engine:
- Significant performance improvement to scripts. Script running speed restored to a level close to AGS 3.2.1. Testing few "script-heavy" games showed fps raise by up to 30-40% compared with 3.6.0 engine.
- Improved performance of String objects in script. For instance, appending a character to a String is now roughly x2 times faster, *sequential* iteration of String.Chars[] in Unicode mode is about x12 (!) times faster (Strings in ASCII mode have relatively less improvement, because they have been faster than Unicode mode already).
- Improved performance when creating, deleting and manipulating Overlays; allows the game to have thousands of those with much less slowing down.
- Improved performance when updating and deleting dynamic sprites, and notifying any objects that have to redraw themselves. Engine no longer resets Graphic properties of objects referencing deleted dynamic sprite to 0.
- Implemented "texture cache", in addition to the existing "sprite cache". The texture cache keeps textures generated from raw sprites and lets reusing them, improving performance and reducing CPU workload. The textures mostly occupy the video memory (on GPU). The actual impact is proportional to the game's resolution and amount of simultaneously animated objects on screen.
- WFN font renderer now supports unicode texts in utf-8.
- Buttons, ListBoxes and TextBoxes now support Right-to-left text direction.
- DrawingSurface.DrawString now supports Right-to-left text direction.
- All the script File functions now treat paths in case-insensitive way (including subdirs), which makes them platform-independent.
- Removed an automatic SetRestartPoint() call at startup. This is done in case user does not want to use default "restart" save slot, or has a custom save system.
- Support handling multiple mouse clicks per game frame, similar to how multiple key presses were supported since 3.6.0.
- When starting up, engine will now precache only first 4 or 8 loops of the starting player character's View. This is done to avoid filling sprite cache with too much sprites at once in case when the player's View contains lots of additional animations.
- Characters will now have their graphic offsets, set by Character.z property and LockViewOffset() function, scaled along with the character's own scaling. This is done so long as the respective game option is enabled in the General Settings.
- Ensure that character and object scaling is updated even when the game is not drawn. This fixes rare issues when their scale property did not update in time whilst the game was completely fadeout, and similar cases.
- Allow to change Character's move speed while its moving.
- When Character is ordered a new move command while already moving, the engine will try to make a smooth transition between old and new moving without a delay.
- Engine will now log a warning for the most incorrect parameters to Animate function instead of quitting the game.
- Engine will now skip blocking Character.Say commands instantly while skipping a cutscene.
- Added new config settings in "graphics" section: "sprite_cache_size" (which replaces deprecated "cachemax" in "misc") and "texture_cache_size".
- Character.AnimationVolume now applies to the portrait animation too.
- Object.SetView now lets invalid loop and frame values, and fallbacks to using loop 0, frame 0, printing a warning. This is also consistent with backwards-compatble SetObjectFrame() behavior.
- Changed Object.SetView() to not play a frame's sound, which could lead to a duplicated sound play if Object.Animate is run right after.
- Text Overlays internal images are now registered as dynamic sprites, and their IDs may be read from Overlay.Graphic. This lets find out their sizes using Game.SpriteWidth/SpriteHeight and optionally draw them somewhere using DrawingSurface.DrawImage().
- Ensure all the script API is now correctly available for the plugins.
- Engine will disable vsync in a "infinite fps" mode, because vsync prevents getting more fps.
- Engine will force any in-game debug messages to be displayed in standard message boxes, disregarding game's "Display all messages as speech" option.
- Deprecated in-game "console", as practically useless.
- Added new config settings in "graphics" section: "sprite_cache_size" (which replaces deprecated "cachemax" in "misc") and "texture_cache_size".
- Fixed Characters may be seemingly "walking in place" for some time when arriving at destination.
- Fixed speechlines were adjusting their Y position while trying to not overlap GUIs even when these GUIs are completely offscreen.
- Fixed first Sierra-style speechline in a sequence was adjusting its Y position without need when GUIs are set to be hidden during game pause (this includes blocking speech). Normally, the speechlines are adjusting their Y position in order to not overlap GUIs, but when GUIs are hiding during speech there should not be any need to do so.
- Fixed script behavior in case a local variable was assigned a value without being initialized with a zero memory by compiler's instruction beforehand. This is not a problem with the standard compiler, but technically could be an issue with any custom implementation.

Engine Plugin API:
- Fixed IAGSEngine.GetFontType() incorrectly reporting TTF font type for WFN fonts with more than 128 characters.
- Added IAGSEngine.ResolveFilePath() method, which resolves a script path (with location tokens) into a proper system filepath.

Compatibility:
- In Editor, restored all the Character's variables available in "backward-compatible" mode. This is primarily to make it easier to import very old games.
- Fixed slower character walking speeds in pre-3.1 upscaled and high-resolution games.
- Fixed Object.SetView() and SetObjectFrame() not treating -1 for loop and frame as "keep previous values" in older games.
- Allow to run an animation over a loop with zero frames, by using the placeholder frame. This lets particular old games to continue running instead of crashing with error.
- Fixed inventory window not updated after game.top_inv_item is assigned a new value.
- Fixed a "New Room" command in old-style dialog scripts was preventing "First time Enter room" event to be called.

Web / Emscripten:
- Fixed Safari cannot switch the game into fullscreen mode.

WinSetup:
- Added options for setting texture cache and sound cache size.





Log Panel

We're now featuring a new Editor window called "Log Panel".



If it's not present, it may be enabled in the "Window" menu.

This panel receives log messages from the engine when running the game in a test mode (F5), and prints in the text box. This is a short-term log, it's limited by 4k messages (i think) and when hitting the limit it will clear the older ones. Its main purpose is to let users see the current and the recent state of the game.

The log settings may be configured by pressing the "Show configuration" tool button, this will make them visible to the right from the log window. The settings include 2 groups of settings:
* Log Output - lets configure the minimal level of messages that the Editor will receive. These options are only applied once the game is starting.
* Log Filter - lets configure the current (temporary) level of messages. These options may be applied anytime.

The message types are dividing between Main, Game and Script.
Main - is the main engine messages, mostly related to something important initializing or changing.
Game - are various game-related events.
Script - are messages printed by a System.Log command in script.

The Log window's font may be configured separately, in Editor Preferences, on "Advanced" tab.

Expanded interaction functions

Regarding expanded interaction functions, these are functions connected to Look at, Interact, Talk to and other similar events. They all now may have 2 parameters: a pointer to object, and cursor mode, similar to the following examples:
Code: ags
function Ego_Interact(Character *c, CursorMode mode)
function oObject1_Look(Object *o, CursorMode mode)

Exceptions:
- Hotspot WalkOn and MouseOver events do not have CursorMode parameter.
- All Region events do not have CursorMode parameter.

The purpose of this addition is to improve situation where you connect same function to multiple events and/or multiple objects at once. In such case you will be able to distinguish object and mode for which the function is actually called.

These new parameters are optional. If you don't have them declared in script, they will be ignored by the engine, and your script is going to run as before.
Also, naturally, you do not have to use them, if you don't need to (even if they are declared).

WFN fonts supporting Unicode

Engine can now draw unicode texts using WFN fonts too, if WFN fonts have appropriate letters.
Unfortunately, existing WFN editors do not let add letters at indices higher than 255. This means they need to be upgraded to allow arbitrary higher slots.
Current WFN format does not exactly have a limit to the glyph index, but it has a limit to 64k bytes of letter pixel data. This amount potentially allows it to store several alphabets in low-resolution within a single font. You may always split languages into separate fonts anyway.

Here's the modified Radiant's FontEdit which supports editing any character in range 0-65535:
https://www.dropbox.com/s/xth28bfzu78vtqi/FontEditUni.zip?dl=0
this is an "unofficial" version made purely for test.
The source project may be found here (if anyone is interested):
https://github.com/ivan-mogilko/fontedit
The example of the WFN font hosting Greek alphabet (only capitals, for test):
https://github.com/adventuregamestudio/ags/files/11540578/AGSFNT0_UNI.zip
may be tried with e.g.
Code: ags
Display("ΟΙ ΘΕΟΙ ΤΟΥ ΟΛΥΜΠΟΥ"); // THE GODS OF OLYMPUS
SMF spam blocked by CleanTalk