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 - Rik_Vargard

#1
Quote from: Crimson Wizard on Fri 08/08/2025 22:38:43This does not involve scripting. In AGS you can configure audio types to crossfade previous playing clips with the next clips.
If you add a silent music clip, you can start it after the previous music, and the music will crossfade to the silent clip, which may sound like it's fading away.

The problem is that I can't find how to only do this for certain pair of clips.
If it's not possible, then maybe there could be made a separate audio type just for this purpose (like "crossfading music" type).

Hey I really appreciate you trying to do whatever we can with what we have!  (nod)
But since you mentioned AGS 4 new Video possibilities, I finally found out another nice way for that moment in my game.
The reason, also, is that I stayed with "Videos block everything" in my head... so I was afraid nothing would work.
Thank you so much for your time!


Quote from: Eon_Star on Yesterday at 20:23:47Hi,
Did not quite understand the question but you may have an audio track that  was formatted as a "fading out audio track" say using an audio editor. It might work.
Happy coding.

Hey thx for your reply!
The thing here is that the music is a background music during a scene with dialogs, thus the player can skip whenever he wants, but the music still has to go on.
So I can't know how much time the player will be in that dialog.
That's the reason why I created that video with no sound, but being played while the background music is playing.

So there's no way I can calculate any timing in this case.

Cheers!  :)
#2
Quote from: Crimson Wizard on Fri 08/08/2025 19:38:03AGS 4 has more advanced video controls, so this may be done easily there.

I can't wait to see what the Video part will be like in AGS 4  (nod)

Quote from: Crimson Wizard on Fri 08/08/2025 19:38:03EDIT: I have a weird idea that maybe this could be done if you start crossfading to a another, silent music track right before PlayVideo. I have never tried that myself.

Yeah my Eternal Scripting Noob Brain doesn't quite understand this.
But since AGS 4 will make that possible, let's forget this right now, I'll find another way to create that part.

Thanks a lot for replying.
Cheers! :)

#3
Hiya! Well like the title says, I want to fade out a song while a video is played, if that's possible.

Here's what I got so far, looks like the video is blocking the script:
I tried both function room_RepExec() and function repeatedly_execute_always()
The Video plays first and only once it's finished does the fading happen.

Code: ags

function room_AfterFadeIn()
{
  SetTimer (1, 20);
  PlayVideo ("Video03.ogv", eVideoSkipAnyKeyOrMouse, 21);
}

function repeatedly_execute_always()
{
  if (IsTimerExpired (1))
  {
    if (BGM.Volume == 0)
    {
      SetTimer (1, 0);
    }
    else
    {
      BGM.Volume -= 1;
      SetTimer (1, 2);
    }
  }
}


Any ideas?  :)
#4
Quote from: Crimson Wizard on Fri 08/08/2025 17:58:34I also noticed that the game has "save into the game's folder" option enabled by default.

Could you please tell me where to find that? I couldn't find it in the Global Setting under Saved Games nor Compiled...?


I didn't try it with 3.6; I compiled the first part of my game with 3.5.
When I compiled my game and started a new one from scratch, the saves' text would not appear, but when I hovered in the empty list, the spots where the saves were did get highlighted even if clicking on them did nothing.
The only way I managed to avoid that was to remove the saved games from the Windows folder before compiling.
Maybe it's a "same computer" thing but it worked that way.
#5
Quote from: SCO on Thu 07/08/2025 10:27:38Hey, I had a question about the game files.

This game comes with several ags###.sav (the default name for AGS saves, although the game apparently uses another name since they don't appear in the load menu) files in the main directory if you extract it. I want to delete these files because they take up quite a bit (about 100+ mb).

Now usually for the Ags engine save files are completely useless to make a game function if you're going to start the game from scratch, and also I can easily imagine a way for a dev to forget to delete those files he was playtesting with before release.


Trouble is, since I'm algorithm minded, I can ALSO think of a way a dev can use a bunch of preexisting save files as chapter checkpoints when starting a new chapter, to guarantee that the new chapter starts with a known state.


So my question is, which is it, can I delete those files?

Here's my experience with that before compiling a game:

Developers will of course have save files to test their game.
Just deleting those save files in-game won't work; there will be "invisible" saved games in the GUI.
Before you compile your game, you should remove the saved files from your Windows Saved Games folder.

#6
Quote from: Crimson Wizard on Wed 30/07/2025 11:14:39EDIT:
In theory it may be possible to readjust game camera based on display resolution, and have it display less portion of a scene at once. I've never tried, but I believe it may be done. Whether it will be convenient or not for the player, I cannot tell.

I have that 1280*720 room where, when the player talks to NPCs, I zoom in to 640*360 and the visuals still look great.
(if that's what you're talking about)
#7
From my experience with many AGS games, any resolution proposed by AGS in the General Settings works great, whatever your screen resolution is.
You'll also notice that the options give a screen resolution ratio.
If you have a 1920*1080 screen (like most of people have), you'll want to go with anything that's 16:9, but if your game is, let's say, 640*480 (thus 4:3 ratio), it will still look great on 1920*1080, just with black boxing on left and right.
Even if you go for 320*180 (16:9), it will still look great on a 1920*1080 screen.

AGS does a really great job to have those low res games look perfect on a high res screen.

That's why the first part of my game was at 1920*1080, and the second part is 1280*720. Because it looks just as great for half the Mb pricel
Which also means you don't need to go 2k  :-D
#8
Aaaah well, when I saw the code I thought I had to understand it to adapt it to my specific needs.
This is my first Module experience  8-0

OK, so this is working, just like that! (nod)
Hmm, I might start to try some other modules now!

Thanks a lot for your help, guys, my game is saved, once again.

Cheers!  ;-D
#9
Hey thx for the links! But right now, those modules are far above my level of understanding.

So at this point , if there's not really a basic AGS script that can do the trick I'll adapt this to what I can do.
I'll try this with a button that will save the messages and make the next Text Box visible once I click on it.  :P
#10
Hi!  :)

I've created a GUI with 4 different Text Boxes for the player to fill in.
Each Text Box has, of course, it's own Name for the scripting part : tbText01, tbText02, etc.
And then I'll create a Variable like Text01 = tbText01.Text;  for each one.
And then I'll have that NPC be like cNPC.Say ("OK listen, %s.", Text01);

Now, when the GUI shows up and I start to type text in one of the Text Boxes, all 4 of them are filled in at the same time with the same text.

How can I make it so that every Text Box can be filled in with it's own text (The player selects a Text Box and starts typing the text just for that Text Box) ?

Any ideas?
Thx!  :)
#11
Quote from: matdogpig on Sat 26/07/2025 16:13:36I reckon this is maybe the first third of the game, maybe a quarter. So the full game will be 3 or 4 times longer. If I ever finish it!

From a Noob with 3+ years of experience and just now arriving at the end of my game:

Most people will say: Start small, make different short games. Well, I coudln't help myself.  (roll)  (laugh)
One of the reasons is that I put so much work in character creation and visuals and animations etc and etc.
I made the choice to learn AGS alongside making that game I wanted to make. So in every Room, or Instance, I tried something new or coded something differently.
At this point, I sometimes go back to earlier Rooms to clean up the script with those XP I got along the way.
I also have those old Rooms that, script-wise, are chaotic but working, so I don't dare to touch anything anumore.  (laugh)

Also, you might have noticed that imagining things for your game and then have to create all the visuals, audio, animations, and the script, there's a lot of time that you will need to make it a reality in your game, right?

I don't know how much time you needed to finish this first part, but imagine taking that time 3 or 4 times for your game.

This being said, I'm sure that whatever your choice is, you'll get to the end of your project.

Cheers!  :)
#12
Quote from: CharleeMK on Wed 23/07/2025 07:35:10I want one button to stop the dialog an another to go back to the previous dialog, that's it, no scrolling or fancy stuff. I know that the easiest way is using the dialog options for that but I wanted to include those buttons for design reasons.

If you just need those two buttons, you could have two normal dialog GUIs and then add a GUI under that with those two buttons and then have the dialog GUIs being Visible or not by clicking on the buttons?

If you need a dialog GUI with all options being buttons, you could create a GUI and the buttons you place in it. Then you could make the option buttons visible or not when choosing options. Then you could even add those two buttons to make those GUIs Visible or not again.
#13
I agree, the graphics are really gorgeous  (nod)
#14
Thank you for your explanations.  (nod)
#15
I started playing "Enlisted". In this game, you can buy new soldiers for your squad. You use in-game money (not real money) and it's not even a "random loot box thing" (maybe the stats of the soldier are random dice rolls) but I do get a message, because I live in Belgium, to be sure I accept to "pay" for it, even with in-game "money".

I think it's a good thing because I guess that many younger players, who don't realize what this is, might want to spend a lot of money just to have a new gun and don't realize how much real money they spend on all those "random upgrades".
#16
Hey thanks a lot for the replies!  (nod)

Now here's what I "found out".

I do set the player to start in later rooms so I don't have to play throught the whole game everytime I change things, like creating a new Dialog.
So I'm sure that overlooking the "Stop" created that situation I was in.

But here's the weird thing: while I was waiting, I did restart the game from the very beginning as it's supposed to be, and when I arrived at this point, the Dialog showed perfectly, no problems, AND there was still no "Stop", eveything was still on "resturn" But it works... ???

So the mystery for me is: Is there a difference between starting the game at Room 1 and starting it at Room 57?
Perhaps I did something on the way that made that problem happen?

EDIT: And now I did restart from Room 57 and everything is OK, when before I had those problems.... still no "Stop"...  still a mystery to me...
#17
Hi!

I have this problem where, when I start the dialog, the GUI doesn't appear.
It happens in a very basic room, where the player just enters the room, meets an NPC and then the dialog has to start.
But it doesn't. And the game "freezes" somehow and then I get the (not responding) thing and the Windows "loading" cursor turning forever.
Then when I click to close the window, it closes and I get the "Not closed properly" error message.

Then I added an option in the Dialog with the NPC saying "Blablabla".
This time, the dialog GUI still doesn't appear, but the NPC says "Blablabla" in a loop, like forever.

In After FadeIn : (GUI not showing)

Code: ags
cAlien01.Say ("What do you want?");
dDialog1.Start();

In the Dialog page: (Sayin "Blablabla" in a loop forever)

Code: ags
@1
cAlien01: Blablabla
return

I have many dialogs, so I don't know what's wrong with this one.

Any ideas?

Thx!
#18
If you want to record what's on your screen while you play you can use OBS Studio. It's free and easy  (nod)
#19
Hey, thank you so much for your time and your work. (nod)

And please forgive me but I don't know if you're talking about the Github or the in-AGS manual...
To me it sounds like both but that might just be my own level of "english understanding"...  :-[
#20
Nice to hear it worked out  (nod)
SMF spam blocked by CleanTalk