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

#41
Hi all, I guess I'm bringing up an old topic, but that's what us newbies do. I was looking for a way to easily add credits at the end of a game. This module seemed like the answer, but the link is broken. Maybe somebody has this laying around. :-D
#42
Oh gosh, I think you nailed it now. My bad for not reading the other messages closely enough. Gotta slow down self.

QuoteNOTE: When the player leaves the screen, all the walkable areas are reset. Therefore, if you want an area to remain off when they leave the screen, you will need to set a flag, then run the RemoveWalkableArea command in the "Player enters room" event when they return.

I always tested that room in one shot. I never left and came back. Guess I just assumed the state of the walkable areas was saved along with the rest of the room state. That doesn't makes sense to me, but I guess it is what it is.

This room actually has 1944 lines of script. I use every available walkable area. Ladders move back and forth, lock, unlock, retract when players move. This puzzle is as she said "annoying" I think. Hope you all hate it! :wink:

I'm so appreciative of the help from all of you!

Oh, I should have mentioned that Lady_Ogress did a great job of testing this. She sent me her save game file which proved to me that the error was indeed real.

It turns out I already had the flags for other reasons. So a much easier fix than feared:

Code: ags

function room_Load()
{
  // remove walkable areas if ladders not in place
  if (!Ladder1and2_connected) RemoveWalkableArea(2);
  if (!Ladder4_in_place) RemoveWalkableArea(4);
  if (!Ladder13_in_place) RemoveWalkableArea(6);
  if (!Ladder14_in_place) RemoveWalkableArea(7);
  if (!Ladder8_in_place) RemoveWalkableArea(9);
  if (!Gangway_connected) RemoveWalkableArea(10);
  if (!Ladder10_in_place) RemoveWalkableArea(11);
  if (!Ladder12_in_place) RemoveWalkableArea(13);
  if (!Ladder15_in_place) RemoveWalkableArea(15);
}
#43
I really appreciate the replies. Thank you.

This is a really tricky one because I can't reproduce the error. I test software for a living, so I know what it is like to be told "I can't reproduce your error, so it doesn't exist." by a developer. I don't want to be that sort of developer, so I think I'll put the code in room_Load anyway. I've been all over this code, and just can't figure out why it doesn't work. A set break point moves right through the function every time. Oh well...

My post reads like frustration so I apologize if I came across negatively. Thanks again.
#44
Okay, it's obvious I don't know what I'm talking about when trying to help others with code. So let me try to ask a question then before I do something wrong.

I've used the following types of statements many times to remove walkable areas. They seem to work, but then one of my testers started a game and the walkable areas were not removed.

Code: ags

function room_FirstLoad()
{
  RemoveWalkableArea(2);
  RemoveWalkableArea(4);
  hLever.Enabled = false;
}


I do have code in room_Load (variable and attribute setting only), room_AfterFadeIn, room_RepeadlyExecute (lots of stuff). The after-fade-in code does blocking activity (characters walking in the room).

The only explanation I have is that somehow she pushed a button and prevented the FirstLoad code from running. So I want to prevent that from ever happening. I was going to move all the RemoveWalkableArea's into room_Load and set up a room-scope boolean variable to check for first load. This is to force the areas to be removed (by having them happen before the fade in).

Does this sound like a good plan? I really don't want to see these walkable areas not getting removed.
#45
That function only works when the players feet are in exactly the same place. It sounds like you'll have to compute the distance between characters. Maybe something like this:

Code: ags

  float delta_x, delta_y, distance;
  
  delta_x = IntToFloat(cmonster.x) - IntToFloat(cEgo.x);
  delta_y = IntToFloat(cmonster.y) - IntToFloat(cEgo.y);
  distance = Maths.RaiseToPower((Maths.RaiseToPower(delta_x, 2.0) + Maths.RaiseToPower(delta_y, 2.0)), 0.5);
  if (distance < 30.0) cEgo.ChangeRoom(17, 181, 105);
#46
removed incorrect statements
#47
I have a suggestion, although I'm not sure how good it is. You could use the custom dialogs available in AGS and add some images for saving/restoring etc. into the dialog itself. You could then use the dialog_options_mouse_click function to catch the mouse clicks and send them to the code for saving & restoring (while also killing the dialog). Here is an example:

Code: ags

function dialog_options_get_dimensions(DialogOptionsRenderingInfo *info)
{
  // Create dialog options area
  info.X = 138;
  info.Y = 128;
  info.Width = 180;
  info.Height = 70;
}

function dialog_options_render(DialogOptionsRenderingInfo *info)
{
  // Clear the area
  info.Surface.Clear(Game.GetColorFromRGB(192, 192, 248));
  // Draw the image buttons
  info.Surface.DrawImage(4, 1, 443);
  info.Surface.DrawImage(16, 1, 444);
  // Set the dialog options to begin below the images
  int i = 1,  ypos = 12;
  // Render all the options that are enabled
  while (i <= info.DialogToRender.OptionCount)
  {
    if (info.DialogToRender.GetOptionState(i) == eOptionOn)
    {
      if (info.ActiveOptionID == i) info.Surface.DrawingColor = 14;
      else info.Surface.DrawingColor = 4;
      info.Surface.DrawStringWrapped(5, ypos, info.Width - 10, eFontSmall, eAlignLeft, info.DialogToRender.GetOptionText(i));
      ypos += GetTextHeight(info.DialogToRender.GetOptionText(i), eFontSmall, info.Width - 10);
    }
    i++;
  }
}

function dialog_options_get_active(DialogOptionsRenderingInfo *info)
{
  int i = 1,  ypos = 0;
  // Find the option that corresponds to where the player clicked
  while (i <= info.DialogToRender.OptionCount)
  {
    if (info.DialogToRender.GetOptionState(i) == eOptionOn)
    {
      ypos += GetTextHeight(info.DialogToRender.GetOptionText(i), eFontSmall, info.Width - 10);
      if ((mouse.y - info.Y) < ypos)
      {
        info.ActiveOptionID = i;
        return;
      }
    }
    i++;
  }
}

function dialog_options_mouse_click(DialogOptionsRenderingInfo *info, MouseButton button)
{
  // this would call your save & restore code
  if (mouse.x > 2 && mouse.x < 12 && mouse.y > 1 && mouse.y < 11) {
    StopDialog();
    save_game();
  }
  if (mouse.x > 14 && mouse.x < 24 && mouse.y > 1 && mouse.y < 11) {
    StopDialog();
    restore_game();
  }
}


Here is the example dialog rendered showing two arrow images (sprites 443 & 444) and some dialog options:

#48
Hi all, I joined several days ago and also didn't see this thread. So thanks to Davi for pointing it out! I'm certainly no spring chicken, but have loved adventure games forever. The short story is my kids grew up and gave me back some free time. I then discovered old adventure games through GOG. And that led me to grab a bundle of games from Wadjet Eye (Gemini Rue, Resonance, etc. - you all know). And Dave Gilbert with his comments at the end... "We used AGS". What! what the heck is AGS? Of course I discovered a wonder of nature here. We live in a world where you can create your own games in a fraction of the time! Where have I been? Who would have known? Oh, did I mention those kids going to college? Anyway it's great to be here and to have a place to explode with a lifetime of creative energy! I will be making games for a long time to come - let's hope. (nod)
#49
Recruitment / [HELP FOUND] Beyond Eternity
Wed 15/04/2015 02:52:50
Beyond Eternity

Episode 1: The West College Disappearances

Update - 27/5/2015
It's too close to the end for any new volunteers. I'm eternally grateful to those who have helped. Thank you.
Details can be seen in this thread: Games in Production

Update - 13/5/2015
:
Most voices are now complete with all others in work. Some testing has been done, but not nearly enough. I would appreciate more help once the voice are incorporated, I get to the beta phase (still really alpha now).

Proof Reading/Editing complete

I have reduced the length of the opening and hopefully it is much more compelling.

Voice Acting

All voice acting is now complete! The status of previous inquiries is below.

Professor Norquist


A volunteer has recently stepped forward (or was the last one left after all others stepped back).

Professor Hansen



My friends have told me my voice is good for this part, so I'm doing this one myself.

Professor Jenkins



The position is taken with about half the lines complete. It's an accented voice and it's great!

Andy



These lines were done until I game him some more lines. It's a fantastic performance if you ask me.

The Librarian



A fellow newby did these lines for me and did a fantastic job.

Professor Wilson



I've asked the Librarian to also do this part which is complete.
#50
Beyond Eternity

Episode 1: The West College Disappearances

The Story

Professors are disappearing out of thin air from West College. How long has this been happening? Where are the Professors going? Why do they not admit facts that others plainly see?

You explore West College to solve the mysterious professor disappearances. You must pay close attention to widely scattered clues. Along the way, you pick up scientific knowledge that uncovers many pieces of the mystery. Time and patience are needed to work through multiple challenging puzzles. Unraveling the evidence could be more important to the future of our Earth than you ever imagined.

Some screenshots











Development Progress

graphics episode 1: 100%
graphics episode 2: 15%
puzzles episode 1: 100%
puzzles episode 2: 10%
scripting episode 1: 100%
scripting episode 2: 0%
music/sound episode 1: 100%
music/sound episode 2: 50%
voice acting episode 1: 80%
final testing of beta version: 0%
expected completion episode 1: June, 2015

Development Diary

The first episode of this game is pretty much complete except for the voice acting. I've updated the opening scene to be shorter and more compelling. I've also spread the rewards out a bit to help the story flow. I don't see any problem with hitting an early June release, as I have a volunteer for the last voice.

I've had a lot of great help from others and I'm very grateful. Hopefully the next update will be a released game!

May 23rd update: The game is now ready for beta testing.

June 4th update: Bugs, bugs and more bugs, but getting closer. Estimate one more week (hopefully).

June 10th update: Not gonna make this week due to testing dragging on. Estimate another week.

June 17th game released. Next is episode 2.
SMF spam blocked by CleanTalk