Adventure Game Studio | Forums

AGS Support => Beginners' Technical Questions => Topic started by: Gilbert on Fri 25/10/2019 02:15:50

Title: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Gilbert on Fri 25/10/2019 02:15:50
This is more or less a successor of this topic (https://www.adventuregamestudio.co.uk/forums/index.php?topic=23558.0).

We are planning to update the original FAQ (https://adventuregamestudio.github.io/ags-manual/FAQ.html) of the AGS Manual to include various common problems encountered when using AGS.

So, if you find something worth mentioning there (such as useful tips and recurring problems) just reply here (usually by including a link to the forum thread mentioning the problems) and we may then update the FAQ.
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Sat 26/10/2019 15:12:36
This question is asked all the time: https://www.adventuregamestudio.co.uk/forums/index.php?topic=57540.0
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Sun 01/12/2019 18:45:31
* How to not have to repeat same command with all the parameters / same chunk of code all the time?
solution: make a custom script function

* How to have Display and still have animations at background?
solution: use GUI and Wait function.
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Tue 03/12/2019 20:22:22
* The function exists in script but calling it causes "function is undefined" error.
Answer:
1) if you are calling from another script, make sure function is correctly declared as import in it's script header
2) make sure function declared/defined above your call in script or placed in a higher script module, move function up if necessary.

* I change settings in Default Setup pane in editor, but in game nothing changes.
Solution: Default Setup affects only default configuration. If you ran winsetup at least once and saved, there's already personal configuration written in your user documents, which overrides defaults. Change the setting by running winsetup as well, or delete user config to reset to defaults.
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: eri0o on Wed 04/12/2019 12:27:00
just adding +1 on how to call a script function elsewhere.
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Sat 07/12/2019 01:01:03
This question was asked pretty many times, in different variations: https://www.adventuregamestudio.co.uk/forums/index.php?topic=57613.0
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Sun 08/12/2019 11:39:16
Q: I loaded my old game in a newer editor, and now I get errors about some AGS functions not defined.
A: These functions were probably deprecated. Check the "Upgrade for X.X.X" topics in the manual to learn about possible breaking changes and how can you adjust your script to the new standard.
If you're in hurry, go to General Settings and set "Script compatibility level" to the version you were making game in previously (that usually works).

(all of those are rough draft ofc and should be improved and expanded)
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: eri0o on Sun 29/12/2019 14:46:56
I added The function exists in script but calling it causes "function is undefined" error. to the manual FAQ on the wiki.
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Mon 27/01/2020 01:00:03
Also asked often:
* How do I do some action when animation reaches particular frame?

* Example:


Code (ags) Select

function repeatedly_execute()
{
    if (oObject1.Animating && oObject1.View == SOME_VIEW && oObject1.Loop == SOME_LOOP && oObject1.Frame == SOME_FRAME) {
         // Do action
    }
}
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Fri 20/03/2020 23:24:25
Also seem to be asked often: how to hide player character in particular room (main menu, intro, etc).
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: fernewelten on Sat 21/03/2020 03:22:52
Quote from: Crimson Wizard on Fri 20/03/2020 23:24:25
how to hide player character in particular room (main menu, intro, etc).

To the best of searching abilities, indeed, "Character.on" isn't described anywhere in the in-Editor doc of the newest official AGS version.

The way to do this that I'd think of first: Set player.on to false in room_Load() and set it to true again in room_Leave().
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: TheManInBoots on Sun 22/03/2020 21:31:34
Aren't outdated, old functions brought up on a relatively regular basis?
Also module-related...
Maybe a section on that could be useful, which then refers to manuals and sections talking about upgrading...

I'm not sure what you mean with "tips", Gilbert, but there is an arrow down button that opens a list of all the labels in the editor. That is extremely helpful when you work with several rooms, and you cannot see all the open tabs anymore. That button is hard to see and could be mentioned as a tip.
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: eri0o on Tue 06/10/2020 14:08:07
@TheManInBoots, wrote a big table of obsolete functions here : https://adventuregamestudio.github.io/ags-manual/ObsoleteScriptAPI.html
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: Crimson Wizard on Thu 03/12/2020 01:31:27
Added all the remaining above from this thread: https://github.com/adventuregamestudio/ags-manual/wiki/FAQ

(maybe in the future we may need to split FAQ in some sections too, for faster navigation, if it becomes overfilled)
Title: Re: Suggestions for items to be added to the FAQ (since 25-10-2019)
Post by: eri0o on Thu 31/12/2020 01:45:45
Ah, a problem I have not figured with the FAQ is having the questions have anchors in some way so a Table of Contents could be available in the to navigate questions. Perhaps the whole questions could be titles themselves.