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

#501
AudioChannel* AudioClip.Play(optional AudioPriority, optional RepeatStyle)

Optionally you can supply a priority and Repeat setting; if you do not supply these, the defaults set for the audio clip in the editor will be used.

This command searches through all the available audio channels to find one that is available for this type of audio. If no spare channels are found, it will try to find one that is playing a clip with a lower or equal priority, and interrupt it to replace it with this new sound.

If all audio channels are busy playing higher priority sounds, then this new audio clip will not be played.

This command returns the AudioChannel instance that the new sound is playing on, or null if it did not play for any reason.

NOTE: AGS can only play one MIDI file at a time.

Example:
Code: ags

aExplosion.Play(); 


Compatibility: Supported by AGS 3.2.0 and later versions.
#502
I guess you should create the function in your Global Script or Room Script as you prefer to keep it work.
No any repeatedly execute required in this case.

Code: ags

// main global script file
function on_event(EventType event, int data)
{

}

/////////////////////////////////////////////

// room script file
function on_event(EventType event, int data)
{

}
#503
Quote from: Nanuaraq on Wed 14/01/2015 16:47:41
whenever it reaches 0

What would happen if chasetimer for absurd is < 0 ?

#504
Quote from: MiteWiseacreLives! on Tue 16/12/2014 17:53:02
use Enters Screen After Fadein instead

Okay, did you do that ?
Code: ags

function room_AfterFadeIn()
{
  aPOL_lens_flare_short.Stop();
  cChar2.Transparency = 100;
  cChar2.FollowCharacter(null);
  cEgo.Move(316, 10, eBlock, eAnywhere);
  mouse.DisableMode(eModeAttack);
  cEgo.LockViewFrame(78, 2, 0);
  cEgo.SpeechView = 79;
}
#505
Ciao RetroJay, :)

You are very nice and kind.

Quote from: RetroJay on Tue 09/12/2014 04:20:54
I wanted to use the Speech Style - 'SierraWithBackground' as I have a nice little portrait to go with the speech.

The SierraWithBackground, as you may have noticed, it puts the game on pause.
And then, it releases on unpause game, so...

Quote from: RetroJay on Tue 09/12/2014 02:09:21
What needs to happen is that when you press key (A or Z) the message is shown and the game pauses (still showing the message.)

This might be difficult to do with SierraWithBackground.
Similarly, you can create your own GUI with the portrait and the same GUI will be where the message comes out.


I tried lately to open a default game,
I created an hotspot and the GUI ("where the player speech") and to make the interaction via stand on hotspot
Worked well by pushing for example A, game paused and the label is showed, nothing more.
Then, by pressing any key, it disappear and return to unpause the game..

Maybe there is something wrong with the AreThingsOverlapping ?
Because as you said, you have many in the script that detect every interaction with objects..

AreThingsOverlapping

Checks whether two characters or objects are overlapping each other on screen.
Returns 0 if they are not overlapping, or the overlapping amount if they are.

I hope I helped further, however, I wish you all the peace of this world to make your game done :-D

:EDIT: The Speech style here doesn't matter at all. Character.Say unlike the Character.SayBackground doesn't returns immediately.
I would create only a GUI with a label - where the player speech -
#506
There may be many reasons which occurs this - bug :)
Especially when you say that :)

Quote from: RetroJay on Mon 08/12/2014 23:15:48
Code: ags

  // Etc...(There is a considerable amount of script after this.)

If this is a platform game however,
I would use hotspot or region to detect this type of interactions
I think they are more flexible and easy to handle.
For example then, you can simply write something like this

Code: ags


bool first_time;

function region1_WalksOnto()
{
   if ( !gMansion_Map.Visible && !gQuit_Dialog.Visible )
   {
       if ( IsKeyPressed(eKeyA)  &&  first_time )
       {      
          player.LookAtObj(oObject1.X, oObject1.Y, "Bla Bla Bla");
          first_time = false;
       }
    }
}

/////////////////////////////////////////////////////////////////////////////////////////
// function LookAtObj(this Character*, int x, int y, String Text)
// {
//     player.Walk(x, y, eBlock);
//     player.SayBackground(Text);
//     // eventually face location / add-lose inventory item / etc etc
//  }
////////////////////////////////////////////////////////////////////////////////////////


Have you tried with region or hotspot already ?
#507
Uncreative hint,

Likewise, use Y++; to move the cloud down or  Y--; to move it up.
X--; to move it left, X++; to move it to the right   :)
#508
Creepy Happy Ending ^^
#509
FMV GAME ! Finally ! :-D


I Love this game, and very well done !
Congratulation Shaun for the release!
#510
Sorry Formica.
I didn't understand when you say :

Quote from: formica on Tue 25/11/2014 23:08:05
and if I click to the right of the OK button

Do you mean by pushing the button OK ?
Or do you mean clicking somewhere else next the button OK ?
As you probably know already, you can detain many things in this way.

Code: ags

function ButtonOK_OnClick(GUIControl *control, MouseButton button)
{
  if (button == eMouseLeft) { }

  if (button == eMouseRight) { }
} 


or

Code: ags

function gInventory_OnClick(GUI *theGui, MouseButton button)
{
    if (button == eMouseLeft) { }

    if (button == eMouseRight) { }
} 
#511
I'm not sure if this hint could be helpful, but I just try to guess your issue.
This is my idea, did you check this section already ?

int InvWindow.ItemHeight; / int InvWindow.ItemWidth;

Gets/sets the height of the rows in the inventory window. You should generally set this up in game_start to the height of your largest inventory item.
The default is 22.

Example:

Code: ags

invMain.ItemWidth = 50;
invMain.ItemHeight = 30;



#512
Said from Vincent sound like a joke.
Because I still keep on to do the same mistake.
But I try ("anytime") to keep in mind these words.


<<(([[|| * READ FIRST *BEFORE* POSTING!!! (updated 14 August 2012) * ||]]))>>

Also keep in mind, Chris Jones (aka CJ aka Pumaman) PAYS for the bandwidth of these forums out of his very own pockets.

#513
Monsieur OUXX, nothing to contextualize.

Quote from: Monsieur OUXX on Sun 23/11/2014 18:53:38
AprilSkies is right : you never ever need to reset all your rooms manually.
You just need two things:
1. Define the place in the game that you consider to be "the beginning" (most of the time, it's the main menu screen) : In that room script, add instruction "SetRestartPoint();".
2. Whenever you want to start a new game, call "RestartGame();" It will not only bring you back to the "restart point", but it will also reset all memory as it was when you called "SetRestartPoint", effectively starting a new game.


It's so extremely important to "Re-type in" what AprilSkies has already saying ?
The manual is free. And everybody can have the manual.


but especially,

Quote from: Monsieur OUXX on Sun 23/11/2014 18:53:38
First, try that, and then we'll see if you still need to fix your scaling issue.

Quote from: rmonic79 on Sun 23/11/2014 16:11:03
works fine, thanks guys, i solved the other scaling problem setting manual scaling on, and the problem is gone.
#514
A quick response could be like this

Quote from: Gabarts on Mon 24/11/2014 12:37:45
-Checking if my player is in a certain room

Code: ags

if (player.Room == 1) //OR if (player.PreviousRoom == 1)


Quote from: Gabarts on Mon 24/11/2014 12:37:45
and then if item is used

Do you mean :

InventoryItem* Character.ActiveInventory

// This property is useful in "Use inventory on hotspot/character/etc" events, to find out which inventory item the player is trying to use on the target.


Quote from: Gabarts on Mon 24/11/2014 12:37:45
I need to use to check if the player has a certain score

Code: ags

// repeatedly_execute()
Label1.Text = String.Format("%d", game.score);



Quote from: Gabarts on Mon 24/11/2014 12:37:45
and then made a GUI to return it.

???
#515
Quote from: rmonic79 on Sun 23/11/2014 12:13:03
and i have a little problem, when i return to main menu and start a new game resetting intro
the main charachter is scaling about 70% and i don't understand why :(

I do not know if this has anything to do with this case.

ManualScaling property (character)

Gets/sets whether the character's scaling level is determined by the walkable area that he is walking on, or whether it is set manually by the script.

This is equivalent to the "Ignore room area scaling" checkbox in the editor.
#516
- Not so sure, but -

It's not possible to change "Do not save state in this room", after you confirm it.

You must make a new room with save state disabled and copy scripts and other stuff into it,
But i guess it depend of your intentions.


Quote from: rmonic79 on Sun 23/11/2014 15:29:22
i think it's possible to change room number to 300

Yes, that is possible :)


I guess this clarification from ags notes it's important too -
Room numbers below 300 save the room state; numbers above 300 do not
#517
Ciao rmonic79,

Quote from: rmonic79 on Sun 23/11/2014 12:13:03
some advice?

I regret in advance for failing to respond to your requests.
But, if you don't mind, can you show off about what do you have in your room's script ?!
Because i didn't fully understand this sentence, apart from the entire post,

Quote from: rmonic79 on Sun 23/11/2014 12:13:03
when i return to main menu and start a new game resetting intro (i made a mistake enabling savestate in the the intro room and i can't change the option, i have to make a new room or is there a way to change it?)
#518
I'm out of topic here
But this Module is just AMAZING

http://www.adventuregamestudio.co.uk/forums/index.php?topic=42843.msg568552#msg568552


Quote from: Khris on Thu 10/02/2011 20:51:43
Key binding commands

KeyboardMovement.SetKey(eKMKey key, eKeyCode k);
Assigns ASCII code k to movement key key.
Example:  KeyboardMovement.SetKey(eKMKeyLeft, eKeyLeftArrow);

#519
Edmundito, you are a incontestable legend.
I wait impatiently to be able to use this masterpiece part II.
Continue with your GREAT work.
#520
Beginners' Technical Questions / Re: add value
Mon 17/11/2014 11:45:48
Quote from: Gurok on Mon 17/11/2014 01:58:11
Ah, I think it's pretty simple now that I look at your code again. You should remove this:
Code: ags
Main_Player protagonista;
Items oggetto[1000];
export oggetto, protagonista; // 

from GlobalScript.asc

By doing this, now the display show :
Code: ags

 // 1: health = 90, recover_energy = 5
 protagonista.health += oggetto[Chips].recover_energy;
 // 2: health = 95


Vinvin's noob, Gurok saved Vinvin's butt ^^;
Ciao, Grazie :)
SMF spam blocked by CleanTalk