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

#161
The Rumpus Room / Re: Misheard game titles
Sat 29/11/2014 02:13:49
What the hell.

How about...
Spunky Island.

Or, my personal favourite...
Bare Witch - The Legend Of Scoffing Cock. (laugh)
#162
Retro Wolf.

Holy SHIT.

Come on!!
Surely there has to be some Law here about posting pictures of my Ex-Girlfriend.

Oh! It's you... Sorry! (laugh)
#163
The Rumpus Room / Re: Happy Birthday Thread!
Mon 24/11/2014 19:26:57
Hi BarbWire.

Thank you ever so much for remembering.
I nearly forgot my own Birthday this year.
QuoteSorry I forgot,but I do have a head like a sieve!
You and me both.

I celebrated by spending the evening sitting at work. :(
At least I managed to get more work done to my new game that I hope to show in the GIP forum, soon.

No, not so much a Lost Prince just a Lonely Prince.

Yours.
Jay.
#164
Hi Crimson Wizard.

Ha...Haa!

I see it all now, some of it.
That works like a charm.;-D

Thank you ever so much for your help and patience.(roll)
I really do appreciate it.

All I want to do now is see if I can find a way of excluding some keys, Menu Keys, from being re-definable.
I will have a play and see if I can work that out myself before I trouble you again for your expertise.;)

Yours.
Jay.

#165
Hi Crimson Wizard.

I really do appreciate your help on this matter...However.
This, I'm afraid, has beaten me.>:(

I haven't got a clue what I'm doing nor do I understand what you are talking about.(sorry to be so dim).(laugh)
People will just have to use the keys I tell them to and like it.;)

Yours.
Jay.
#166
Hi Crimson Wizard.

I decided to attempt your code and...
I seem to be having problems with this section of script, from your first piece of code. ???
When I tried this I did set all of my keys up.

Code: ags
function on_key_press(eKeyCode keycode)
{
   <...>
if (keycode == KeyMoveUp)
    ... move up
else if (keycode == KeyMoveDown)
    ... move down
    etc
    <...>
}



Where you have '... move up/down'. Am I supposed to put more lines of code there?
If so, then what? :-[ :-[ :-[

without this section my game plays and when I press the R key to redefine keys my GUI shows and asks me to press buttons for Up, Down, Left and Right.
Then the GUI closes and my game starts but the keys I have selected do nothing, the arrow keys still control my character.

Edit:-
I though that I would show you how my 'On_Key_Press' script is, at the moment.
Code: ags
function on_key_press(eKeyCode keycode) {
  // called when a key is pressed. keycode holds the key's ASCII code.

  if (gKeySetupGUI.Visible) {
    RecordSetupKey(keycode);
    return; // do not do anything else this time
  }


  // THE S KEY (START GAME - FROM OPTION SCREEN).
  // --------------------------------------------
  if (IsKeyPressed(eKeyS) && gMansion_Map.Visible == false && gQuit_Dialog.Visible == false) {
    if (cDan.Room == 2){
      ResetRoom(3);
      ResetRoom(4);
      cDan.ChangeRoom(3, 624, 400, eDirectionLeft); // Pressing the S key starts game from the Options Screen.
    }
  }


  // THE L KEY (RESTORE CHECKPOINT).
  //--------------------------------
  if (IsKeyPressed(eKeyL) && gMansion_Map.Visible == false && gQuit_Dialog.Visible == false) {
    RestoreCheckpoint(); // Pressing the L key restores the Saved Checkpoint.
  }


  // THE Q KEY (SHOWS THE QUIT DIALOG) AND PRESSING KEYS Y=YES AND N=NO.
  //--------------------------------------------------------------------
  if (IsKeyPressed(eKeyQ) && gMansion_Map.Visible == false) {
    gQuit_Dialog.Visible = true;
  }
  
  if (gQuit_Dialog.Visible == true) {
    if (cDan.Room == 2) {
      if (IsKeyPressed(eKeyY)) {
        QuitGame(0);
      }
    }
  }
  
  if (gQuit_Dialog.Visible == true) {
    if (cDan.Room == 2) {
      if (IsKeyPressed(eKeyN)) {
        gQuit_Dialog.Visible = false;
      }
    }
  }
  
  if (gQuit_Dialog.Visible == true) {
    if (cDan.Room == 3 || cDan.Room == 4) {
      if (IsKeyPressed(eKeyY)) {
        RestartGame();
      }
    }
  }
  
  if (gQuit_Dialog.Visible == true) {
    if (cDan.Room == 3 || cDan.Room == 4) {
      if (IsKeyPressed(eKeyN)) {
        gQuit_Dialog.Visible = false;
      }
    }
  }
  
  
  // THE R KEY (REDIFINE PLAYING KEYS).
  //-----------------------------------
  if (IsKeyPressed(eKeyR) && gMansion_Map.Visible == false && gQuit_Dialog.Visible == false) {
    StartKeySetup();
  }
  

  // THE P KEY (MANSION PLANS).
  //---------------------------
  if (keycode == eKeyP) { // Pressing the P key (in game) show the Mansion Plans Screen.
    if (gQuit_Dialog.Visible == false) {
      if (gMansion_Map.Visible == true) gMansion_Map.Visible = false;
      else gMansion_Map.Visible = true;
      if (gInventory.Visible == true) gInventory.Visible = false;
      else gInventory.Visible = true;
      if (cDan.Room == 2) { // However, If the P key is pressed on the Options Screen...
        gMansion_Map.Visible = false; // The Mansion Plans are not shown...
        gInventory.Visible = false; // Neither is the Inventory Screen.
      }
    }
  }
  

  // THE M KEY (STOP OR START MUSIC).
  //---------------------------------
  if (IsKeyPressed(eKeyM)) {
    if (Game.IsAudioPlaying(eAudioTypeMusic)) {
      aThe_Builder.Stop();
    }
    else {
      if (IsKeyPressed(eKeyM)) {
        aThe_Builder.Play();
      }
    }
  }
    
  if (IsGamePaused()) keycode = 0; // game paused, so don't react to keypresses.
}  
// END OF 'ON_KEY_PRESS' SCRIPT.
// -----------------------------


Thank you for your help.

Yours.
Jay.
#167
Hi Crimson Wizard.

That looks... interesting.:P
I will definitely try this out, tonight.

Looking at your script I assume that all of this will be scripted within 'Global Script', yes?
I will let you know how thing go.

Thank you for your time.

Yours.
Jay.

#168
Hi all.

I hope someone can help me out here.
I have been scouring the forums and searching for a solution but, alas, have not found the answer.

The game I am working on is all controlled with the keyboard, I am using the built in 'KeyboardMovement' Module, AGS 3.2.1.
Everything is going well... However...

I would love for the player to be able to re-define the controls.
The keys that I would like for them to be able to change are the movement keys, these are set on the arrow keys, at the moment.
Also Examine and Use inventory item, I have these set on A and Z, for now.

Is there a way of accomplishing what I would like to do?
If anyone could give me a few pointers, it would be much appreciated.

Yours.
Jay.
#169
Hi Vincent.

I decided to test your code out.
It seems to work beautifully.;-D

The only things I changed were the region and room numbers.
My game actually starts in room 3 and the Checkpoint region is 3 (by some strange coincidence.)
Also, the line in 'Repeatedly_Execute_Always' I had to put it in 'Repeatedly_Execute' instead (the game wouldn't compile, otherwise.)

Other than that, Fantastic.;-D

Have a check of what I have below and see if you can see anything I have done wrong.

Code: ags
// VINCENT'S SAVE GAME SCRIPT.
//----------------------------
#define CHECKPOINT_SAVESLOT     5    
// How many you wish, 
// I am one of those people who prefer one state over to save the game

bool SafeArea = false, First_time = true;

int DangerMode = 0, oldregion; //globally would be nice
// 0 = No Danger Mode
// 1 = In Danger Mode


bool CheckpointExist()
{
  return (Game.GetSaveSlotDescription(CHECKPOINT_SAVESLOT) != null);
}


void SaveCheckpoint()
{
  SaveGameSlot(CHECKPOINT_SAVESLOT, "Checkpoint");
}


void RestoreCheckpoint()
{
  if (CheckpointExist()) RestoreGameSlot(CHECKPOINT_SAVESLOT);
}

 
function StepRegion(int reg) {
  if (reg > 0) { // walk on safe area
    if (player.Room == 3 && reg == 3 ) //extra lines to add 'First_time' or 'SafeArea' 
    {
       SafeArea = true;
       Display("Game Saved");
       SaveCheckpoint();
       Wait(1);
       First_time = false;
    }
  }
  else { // walk off the safe area
    reg = -reg;
    if (player.Room == 3 && reg == 3) //extra lines to add 'First_time' or 'SafeArea' 
    {
       SafeArea = false; 
    }
  }
}

 
function ExploringRegion(Region*r) {
  int currentregion = r.ID;
  if (currentregion != oldregion) {
    if (oldregion != 0 && region[oldregion].Enabled) StepRegion(-oldregion);
    if (currentregion != 0 && region[currentregion].Enabled) StepRegion(currentregion);
    oldregion = currentregion;
  }
}


 function repeatedly_execute() {  // This was the only thing I had to change. It wouldn't compile within 'Rep_Exc_Always' but seems fine here.
  // put anything you want to happen every game cycle in here.
  ExploringRegion(Region.GetAtRoomXY(player.x, player.y));
}
// END OF VINCENT'S SAVE GAME SCRIPT.
//-----------------------------------


Just thinking to myself and...
I'm only going to need a 'Load' GUI, aren't I?
As my game now saves automatically then I don't need a 'Save' GUI.

EDIT:
Thinking some more. (This is very dangerous.)(laugh)
I decided that I didn't need a 'Load' GUI, either.
Let's face it, the game auto saves and only makes one save that keeps getting overwritten.
So all I did was add this line
Code: ags
if (keycode == eKeyL) RestoreCheckpoint(); // Pressing L key restores the saved Checkpoint.

to 'function on_key_press(eKeyCode keycode)'

It all works like a dream.

Thank you ever so much for your time, Vincent.

Yours.
Jay.
#170
Hi Vincent.

That's fantastic.8-0

What a thoroughly decent guy you are.(nod)
That's as good a reason, as I can think of, for taking a day off.(laugh)

Thank you ever so much for taking the time to do this for me.
I think your script may be just what I need.

Before I can try it, though, I need to make a save and load gui box.
Also finish some other areas before I implement your code.
I will let you know how things go.

Once again, Thank you for your help, it is really appreciated.;-D

Yours.
Jay.

#171
Hi Crimson Wizard and Vincent.

I have decided to go down a different path and make a save point instead.:-\
Unfortunately, I do need the game to restore precise room state as I have a lot of objects and items that change state throughout.

You see the game I am trying to create at the moment is a platform/adventure.
After much deliberation I felt it would be better to have a save point that is in a safe area where your character cannot be harmed.
When you load the game you will then be in that safe area, ready to continue.

If the game was to save on exit then when you load that save in you might be in an area where you cannot escape being harmed. (that wouldn't be good.)

Crimson Wizard, I totally agree that a 'Game exit function' or something along those lines would be a very good idea.(nod)

Vincent, I have copied your script to my, ever growing, book of useful scripts.
It may come in handy if I change my mind... again.(roll)

Thank you ever so much for your help it is much appreciated.

Yours.
Jay. 
#172
Hi Vincent.

Nice to hear from you.

Thanks for your help.
I will have to try what you have suggested tomorrow, or as it is today, tonight. ;)

I will let you know how things went.

Much appreciated.

Yours.
Jay.
#173
Hi All Good Peeps of AGS.

I hope you are all well.

What I would like to implement within my game is a 'Save Game' feature that only occurs when you exit the game.
For those of you that have played 'Hidden Objects' games, then I trust you know what I mean.

For People who haven't...
When you exit the game then it is saved automatically at the point in witch you left.

Is there a way of accomplishing this or am I aiming too high here?

Yours.
Jay.
#174
Hi Monkey_05_06.

All done.
Phew! That was hard.;)

Yours.
Jay.
#175
Hi Cat.

Just thought that I would let you know.
Dualnames was able to help.;-D

All I've got to do, now, is get it to work.;)

Thanks for your help.

Yours.
Jay.
#176
Hi Cat.

Thanks for that.
I have PM'd Dualnames to see if he can help.

Yours.
Jay.
#177
Hi Baron.

Oh! I see.(laugh)
Thanks for the information.

Do you, or does anyone else, know where I can obtain the module 'Pixel-perfect collision detection v1.02' please.
I don't know if it will help with what I'm trying to do, but I would like to try it.

Yours.
Jay. 
#178
Hi all.

I have a question.
Where has SSH gone?

I tried to download his module 'Pixel-perfect collision detection v1.02' but get the 404 error.
So I decided to try his site but that's not working.
Tried PM-ing him but have received no answer.
Even his avatar is missing (You know, the Scottish Superhero.)

According to his stats he was online today a 06:30.???

Yours.
Jay.
#179
Thanks for the information, Crimson Wizard.

It all looks and sounds good...but...
I think I will hang on until it is officially released.

Yours.
Jay.
#180
Hi Crimson Wizard.

That's good to hear.
Would it be worth me using AGS 3.3.1 WIP version, at the moment or wait a while?

Regarding the 'send error report' It sounds as if you could be right, especially if the server address changed in 3.3.0.
When I tried to send the crash report it said something along the lines of:

'Couldn't connect to server, it maybe busy.
Copy the error report and post it in the Advanced Technical Forums.'

So I thought I would, just in case it helped people who are developing AGS 5.1. (laugh)

Yours.
Jay.
SMF spam blocked by CleanTalk