You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Update todo, changelog and contributors.
* Document basics of touch.nvgt.
* Update website features list to mention Android!
* Properly call java TTS finalizer.
* Remove duplicate form control announcement on window focus in virtual_dialogs.nvgt.
* Add a new speak_to_file test, function is broken right now.
* Astyle a couple of interact tests.
Copy file name to clipboardexpand all lines: doc/src/appendix/!To do.md
+6
Original file line number
Diff line number
Diff line change
@@ -50,6 +50,12 @@ NVGT does have a library object similar to BGT which allows one to call into mos
50
50
### force_key methods
51
51
A rare request is that we add bgt's force_key_down/force_key_up methods and friends to the engine, this is a good idea and we will do so. We are very close now with the new simulate_key_down and simulate_key_up functions, the only difference between these and the force methods is that the player still controls the keyboard E. simulate arrow down then real arrow down followed by real arrow up means arrow released, where as with bgt force methods the arrow key would stay forced down until manually reset.
52
52
53
+
### IOS
54
+
NVGT now has Android support, leaving one more target platform which is IOS!
55
+
56
+
### Android touchups
57
+
Android support is getting pretty stable, but there are a couple of areas that still need improvement. We still need to finish asset management, and so until that is done you must embed a pack file into your app for sounds to be played. More improvements to tts_voice will follow as well, you can only use the default voice at this time and parameter ranges may need adjustment. The gesture support though functional is still very young, and needs more testing and expansion.
58
+
53
59
54
60
## Code improvements
55
61
This section specifically lists tasks we wish to perform related to NVGT's c++ code, repository, or other backend. Other than performance, items here should rarely effect application functionality but are instead designed to allow developers to engage in a bit less painful wincing when reading or contributing to NVGT's code.
Copy file name to clipboardexpand all lines: doc/src/appendix/Changelog.md
+5-3
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,9 @@
1
1
# Changelog
2
2
This document lists all major changes that have taken place in NVGT since we started keeping track.
3
3
4
-
## New in 0.89.0-alpha (unreleased):
4
+
## New in 0.89.0-alpha (10/09/2024):
5
+
* NVGT has now switched to using InnoSetup for it's installer, adding several new options such as adding to path, start menu icons etc.
6
+
* Added the script_function::get_namespace() method as well as script_function::retrieve() which takes a native function handle derived from a funcdef.
5
7
* Including pack files via the `#include` directive has been removed in favor of being able to include scripts of any extension, you should use the `#pragma embed` directive to do this instead.
6
8
* NVGT games now run on intel as well as arm mac computers!
7
9
* The calendar object is now registered as a reference type with Angelscript meaning it now supports handles, for BGT backwards compatibility. The other datetime classes are still value types.
@@ -12,7 +14,7 @@ This document lists all major changes that have taken place in NVGT since we sta
12
14
* ini.nvgt include is now free of bgt_compat! Added quick test for it.
13
15
* Fixed a bug in instance.nvgt include regarding automatic mutex name generation.
14
16
* The compiler now includes a status window that continues getting updated with messages reporting what is currently happening during compilation.
15
-
* Adds refresh_window() function.
17
+
* Adds refresh_window() function, allowing manual pulling for windows events encase you want to use your own sleeping methods.
16
18
* Adds input_forms.nvgt include with functions to quickly retrieve information using an audio form, test/example in test/interact/test_input_forms.nvgt.
17
19
* Introduce new menu system based on audio form, in menu.nvgt. As a result, the old dynamic menu has been renamed to bgt_dynamic_menu.nvgt to make it clear what one is legacy.
18
20
* Registered some new vector functions such as cross, length2, distance and distance2 etc.
@@ -29,7 +31,7 @@ This document lists all major changes that have taken place in NVGT since we sta
29
31
* Add virtual_dialogs.nvgt include.
30
32
* Add datastream.sync_rw_cursors property (true by default).
31
33
* tts_dump_config and tts_load_config in speech.nvgt include can now save screen reader usage setting.
32
-
* ADDED ANDROID PLATFORM SUPPORT, NVGT RUNS ON MOBILE! This includes gesture detection (touch.nvgt include or query_touch_device function), screen reader speech through Android's accessibility event API, and android TextToSpeech engine support through the tts_voice class! The support is still young and there are many improvements still to be made (only the default tts voice can be used right now for example), but even running small nvgt scripts from source is possible at this point with NVGT's Android runner application, and one-click APK bundling is possible!
34
+
* ADDED ANDROID PLATFORM SUPPORT, NVGT RUNS ON MOBILE! This includes gesture detection (touch.nvgt include or query_touch_device function), screen reader speech through Android's accessibility event API, and android TextToSpeech engine support through the tts_voice class! The support is still young and there are many improvements still to be made (only the default tts voice can be used right now and the only way to embed sounds is by using the `#pragma embed pack.dat` feature for example), but even running small nvgt scripts from source is possible at this point with NVGT's Android runner application, and one-click APK bundling is possible!
33
35
* NVGT now has a bundling facility! It can create .apk packages for android (assuming the needed android tools are available), it can create MacOS app bundles on all platforms though only a .dmg on Mac (.app.zip on other platforms), and it can copy Windows/Linux libraries into place as well as bundle your asset files like sounds, readme and changelog all to create a fully distributable package in one click! It can even run custom prebuild and postbuild shell commands in case the bundling facility isn't quite doing enough for your needs. More information is in the compiling for distribution document. This means as an aside that NVGT's compiler application is significantly larger, as it must include the MacOS and Linux libraries on windows, the Windows and Linux libraries on Mac etc for the purposes of creating a fully functional app bundle no matter what platform it is compiled on.
34
36
* The compile script submenu has changed, it now contains options to compile for all platforms you have stubs for!
35
37
* Trying to embed a pack that doesn't exist no longer makes NVGTW.exe silently exit.
Copy file name to clipboardexpand all lines: doc/src/appendix/Contributors.md
+3-1
Original file line number
Diff line number
Diff line change
@@ -6,9 +6,11 @@ This file contains the names of anyone who has helped contribute to the NVGT eng
6
6
*[Rory Michie](https://github.com/RoryMichie): Has done much work on the NVGT user manual.
7
7
*[Tyler Spivey](https://github.com/tspivey): rewrote the executable loader on Windows to work with packers such as UPX, helped make documentation look more presentable.
8
8
*[Harry Min Khant](https://github.com/harrymkt): Wrote several documentation articles particularly in the references section, improvements to nvgt includes.
9
-
*[Ethin Probst](https://github.com/ethindp): major optimizations to parts of the code, rewrote sound effect parsing, libspeechd and Android TTS engine integration, atomics, docs.
9
+
*[Ethin Probst](https://github.com/ethindp): major optimizations to parts of the code, rewrote sound effect parsing, libspeechd and Android TTS engine integration, atomics, innosetup installer, docs.
10
+
*[Ivan Soto](https://github.com/ivansoto0): Several major includes such as input_forms.nvgt, settings.nvgt, touch.nvgt etc as well as various improvements to smaller ones such as bgt_compat, input_forms and others.
10
11
*[Valiant8086](https://github.com/valiant8086): Documentation on game distribution.
*[Hamza Ahmad](https://github.com/literary-programmer): Contributed virtual_dialogs.nvgt include, Improvements to form.nvgt.
12
14
*[Abdullah Tepeli](https://github.com/colonel-official): Delete-by-word support for the audio_form include.
13
15
* Beta testers including but not limited to Patrick Wilson, Quin G, Steven D, Lucas Brown, Liam Erven, DJWolfy, Lukáš Hosnedl, Heaven Games, Pragma and Day Garwood, without the valuable feedback and suggestions provided by these people NVGT would have never gotten this far.
14
16
* Last but not least, nothing is worth maintaining or developing without users, and so thank you to everyone who uses this engine and gives it their feedback, time and attention!
This file indicates that this subdirectory should be considered as a root page in the markdown version of the documentation, see the docgen notes for more details.
Detects and then converts raw touch screen finger data into gesture events which can be detected by your application or even converted to keyboard input.
3
+
touch_gesture_manager();
4
+
## Remarks:
5
+
This is the highest level interface NVGT offers to accessing touch screens. It looks at what fingers are touching the screen and where, and by monitoring that data over time, derives gestures such as swipes and taps from that data before passing them along to whatever interface you register to receive them.
6
+
An interface is included by default (see the touch_keyboard_interface class), which convertes these events into simulated keyboard input for you so that adding touch support to your game becomes as simple as mapping gesture names to keycode lists.
7
+
The basic usage of this class is to create an instatnce of it somewhere, before attaching any number of touch_interface instances to the manager and finally calling manager.monitor() within the loops of your programs to receive gesture events.
Determine whether any touch devices are available to receive events from.
3
+
bool is_available();
4
+
## Returns:
5
+
bool: true if at least one touch device is available on the system, false otherwise.
6
+
## Remarks:
7
+
It is worth noting that due to circumstances outside our control, sometimes touch devices don't appear in the list until after you have touched them at least once. Therefor you should not use this method at program startup to determine with finality that no touch device is available, but could instead use it during program lifetime to monitor for whether touch support appears or disappears.
8
+
*/
9
+
10
+
// Example:
11
+
touch_jesture_manager touch;
12
+
void main() {
13
+
wait(1000); // Give the user some time to touch the screen to make sure it appears.
14
+
if (!touch.is_available()) alert("warning", "This system does not appear to support touch screen devices");
*`touch_interface@[]@ interfaces`: A list of interfaces that will receive touch events.
8
+
*`bool append = false`: Determines whether to append to the list of existing interfaces Vs. replacing it.
9
+
10
+
## Returns:
11
+
12
+
bool: True if a change was made to the interface list, false otherwise.
13
+
14
+
## Remarks:
15
+
You can pass multiple interfaces to a gesture manager because different interfaces can receive different events for various parts of the screen. An interface can simply return false in it's `is_bounds` method at any time to pass the gesture event to the next handler in the chain. Gesture interfaces are evaluated from newest to oldest.
* touch_gesture_manager@ parent: A handle to the manager you intend to add this interface to, parameter subject for removal in future.
8
+
* dictionary@ map: A mapping of gestures to keycode lists (see remarks).
9
+
* float minx, maxx, miny, maxy = TOUCH_UNCOORDINATED: The bounds of this interface, default for entire screen or custom.
10
+
11
+
## Remarks:
12
+
This interface works by receiving a mapping of gesture names or IDs to lists of keycodes that should be simulated.
13
+
14
+
The basic format of gesture IDs consists of a gesture name followed by a number of fingers and the letter f. For example, to detect a 2 finger swipe right gesture, you would use the key "swipe_right2f" in the mapping dictionary. The available gesture names are as follows:
Copy file name to clipboardexpand all lines: test/interact/test_input_forms.nvgt
+6-2
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,7 @@
1
+
// NonVisual Gaming Toolkit (NVGT)
2
+
// Copyright (C) 2022-2024 Sam Tupy
3
+
// License: zlib (see license.md in the root of the NVGT distribution)
4
+
1
5
#include"dget.nvgt"
2
6
#include"input_forms.nvgt"
3
7
void main() {
@@ -12,9 +16,9 @@ void main() {
12
16
input.add_checkbox_field("agreement", "I agree to the rules", false, true, true);
13
17
input.description = "You will be asked the following questions to guide you in your profile setup";
14
18
dictionary@result = input.run();
15
-
if(input.user_canceled) {
19
+
if(input.user_canceled) {
16
20
alert("error", "The user canceled profile setup");
17
21
exit();
18
22
}
19
-
alert("profile", "The user is named "+dgets(result, "first_name")+" "+dgets(result, "last_name")+". They are from "+dgets(result, "location", "unknown")+" and are "+dgetn(result, "age", 1)+" years old. Their favorite operating system is "+dgets(result, "platform", "system7"));
23
+
alert("profile", "The user is named " + dgets(result, "first_name") + " " + dgets(result, "last_name") + ". They are from " + dgets(result, "location", "unknown") + " and are " + dgetn(result, "age", 1) + " years old. Their favorite operating system is " + dgets(result, "platform", "system7"));
Copy file name to clipboardexpand all lines: web/src/index.md
+2-1
Original file line number
Diff line number
Diff line change
@@ -44,7 +44,8 @@ The NVGT engine advertises the following qualities and features:
44
44
* script debugger; Find issues in your code like never before with standard debugging techniques like breakpoints, single instruction stepping, realtime expression evaluation and more.
45
45
* ever expanding plugin system; Be free of the Angelscript sandbox and code whatever extensions to your game you want in c++ or another language.
46
46
* subscripting; Add downloadable levels to your games or make them more dynamic with NVGT's ability to execute Angelscript code from within Angelscript code like the javascript or python eval function.
47
-
* cross platform; Release your games for windows, as well as macOS and Linux!
47
+
* cross platform; Distribute your games to a wide audience by easily compiling it for Windows, Mac OS, Linux and more.
48
+
* games on the go; Let your players take your games with them on their Android devices, with IOS planned for the future. Mobile support still young.
48
49
* 64-bit; Your old BGT projects can now utilize all system resources.
49
50
* 3d pathfinder; Find intelligent paths in 3 dimensions with possibly more in the future.
50
51
* builtin JSON support; Connect your projects to online services using one of the most widely recognized API data exchange languages.
0 commit comments