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

#1261
I don't quite understand what you mean.
I've never used the feature, but choosing "Dump game text to file..." pops up a dialog box where you can tick what parts you want to dump. If you check "Text scripts", that will obviously dump your scripts as well.

I don't see what's particularly messy about it. It's designed to make global changes easier and is supposed to be reimported later. For that to work, AGS has to put some special control lines in there so it knows where everything goes.

If you just need it for proofreading, why not use the translation source dump? AFAIK that dumps every text that's displayed in the game.
#1262
Thank you!
Well, a clear case of RTFM. :P

But I agree with

Quoteif in reality it's not really 0-100 levels the parameter should just use the internal scale (0-63/64 probably).

Edit:

Because since I want do it in the background, that means I need an additional global variable storing the actual transparency. Ah well...
#1263
Are you sure the code executed at all? Try putting a Display command there to check.

Just so we're clear, you have this:

Code: ags

  int vol = 100;
  while (vol >= 0) {
    SetMusicMasterVolume(vol);
    vol--;
    Wait(1);
  }


in the "Player enters screen (after fadein)" interaction of your room, right?
#1264
Additional problems arise if you also want it to work with NPCs, not just the player character.
This tracker entry might come in handy in the future.

Edit:

Btw, here's a template by Scorpiorus demonstrating the technique:
http://www.geocities.com/scorpiorus82/stairs10.zip (right click/save as)
#1265
I must be doing something wrong here:

I want to fade in an object. I encountered a problem and tried this simple code

Code: ags

  object[0].Transparency = 100;
  while (object[0].Transparency) {
    object[0].Transparency--;
    Wait(1);
  }


in hi-color and in 32-bit. The object goes transparent, but doesn't fade in.
The transparency simply doesn't change and the game locks up.
32-bit background, 32-bit object sprite.

Try this demo.

Am I missing something?

I see no way this could be related to Linux, so I didn't boot Windows to check.
Forgive me if it works for you.
#1266
They're the default global messages. Go to the "Global messages" pane in the editor, scroll down and just remove the text of those messages.

What TerranRich probably means is that some of them are used as label texts on the built-in GUIs (inventory, save, load, quit and so on) and should better be left alone.
#1269
Nope, the struct is named Mouse, but its instance is indeed called mouse.

Edit:

Hm, both seem to work. I'm confused now.
#1270
Quote from: egalotron on Sun 08/05/2005 11:02:52Or: Is there any way to set the delay between the different sprites separately?

If you really need the whole background to be animated, you could do it like this:

In a room with 3 background frames, to let the frames stay for 8, 10 and 7 game loops respectively:

Code: ags

// room script file

#define NUM_BACKGROUNDFRAMES 3 // including normal background (maximum 5)

int BackgroundFrameDelay[NUM_BACKGROUNDFRAMES]; // stores the delays of each background frame (in game loops)
int CurrentBackgroundFrame = 0; // stores currently displaying background frame (start with first one)
int CurrentDelay; // stores current delay before displaying next frame


function repeatedly_execute_always() {
  //...

  if (IsGamePaused() == 0) { // if game is not paused

    if (CurrentDelay) CurrentDelay--; // if delay has not expired yet, decrease it
    else { // if delay until next frame has expired
      SetBackgroundFrame(CurrentBackgroundFrame); // display selected background frame
      CurrentDelay = BackgroundFrameDelay[CurrentBackgroundFrame]; // set delay until next frame
      CurrentBackgroundFrame++; // select next background frame
      if (CurrentBackgroundFrame >= NUM_BACKGROUNDFRAMES) CurrentBackgroundFrame = 0; // if reached last background frame, select first one (loop)
    }

  }

  //...
}


function room_x() {
  // script for room: Player enters screen (before fadein)

  //...

  BackgroundFrameDelay[0] = 8;
  BackgroundFrameDelay[1] = 10;
  BackgroundFrameDelay[2] = 7;


  //...
}
#1271
Oh, you mean you can't LEFT-click.
Do you have "Handle inventory clicks in scripts" activated in the General settings?
If so, you have to add a check for eMouseLeftInv in your on_mouse_click and handle inventory clicks yourself.

Edit:

For example:

Code: ags

//...

  if (button == eMouseLeftInv) {
    player.ActiveInventory = inventory[game.inv_activated]; // activate the clicked item
  }

//...
#1272
How do you display the speech (which command)?

3)

Quote
* Auto-number speech lines now does DisplayAt and DisplayThought.
* Added an option to Auto-number Speech Lines to number Display() lines for the narrator.
* Auto-number speech lines now tells you which room the error was in, if there is a compile error when re-compiling.
#1273
http://www.adventuregamestudio.co.uk/yabb/index.php?topic=20582

Quote
* Auto-number speech lines now does DisplayAt and DisplayThought.
* Added an option to Auto-number Speech Lines to number Display() lines for the narrator.
* Auto-number speech lines now tells you which room the error was in, if there is a compile error when re-compiling.
#1274
Are you sure the music is playing in the music channel? Which command do you use to play the music?
#1275
If you want the default right mouse click action to be possible from everywhere, you could do:

Code: ags

function on_event(EventType event, int data) {
  //...

  if (event == eEventGUIMouseDown) {
      if (mouse.IsButtonDown(eMouseRight)) on_mouse_click(eMouseRight);
  }

  //...
}


The on_event function has to be located after the on_mouse_click function for this to work.
Then, in on_mouse_click, I have something like this:

Code: ags

  //...

  if (button == eMouseRight) {
    if (mouse.Mode != eModePointer) mouse.SelectNextMode();
  }

  //...


This way, to disable the right click, I just have to set the mouse mode to Pointer.
#1276
Quote from: strazer on Fri 06/05/2005 16:34:56
Quote from: Maestro on Fri 06/05/2005 14:56:04
I wan't to make two rooms and save them under names room1 and room2.
If the player leaves the room1 via door or simply walking to the edge of the screen, he goes to room2. Now, in the editor you can make that transition crossfade, block out etc. I'm wondering can I make AGS do that transition by making the room2 background scroll in to room1 background so it looks like the viewport moved to the next room.
I've just now started working on a script module for that. With the new DynamicSprite.CreateFromScreenShot it's doable without dummy rooms.
My prototype looks promising, just a few minor things to fix. Watch this space.

Okay, so here's an early version:

Go to menu "Script" -> "Module manager..." and import the file "SlideRoom_052.scm".
Now you can use SlideRoom.ChangeRoom instead of player.ChangeRoom or NewRoom/Ex.

Known problems:
- Characters and objects using flipped view frames will be drawn the wrong way
- Characters and objects that happen to be on the edge of the old screen and are only half-seen appear to be cut off during sliding
- Any repeatedly_execute_always's will run during sliding unless they're not explicitly prevented from running if game is paused: if (IsGamePaused()) return;

With AGS v2.71 I should be able to fix some of these, new version underway...

Download v0.52 (Requires AGS v2.71!)
(Script module only)
#1277
Wow, three awards! Thanks to everbody who voted and congratulations to all winners.
I'm especially happy Joyce won.
#1278
Quote from: TheMagician on Sun 01/05/2005 23:29:46
By the way: I recently got this PM:
QuoteHello,

I'm an editor of a freeware section in a czech paper magazine about computer games, Level. Level is the best-selling gaming mag in the Czech republic, you can find more info about it at www.Level.cz. I'd like to ask you, if you'd agree with publishing your currently released game - winner of the ATC - on our cover CD and/or DVD in the May issue of Level. Is it possible?
P.S.: If you want a copy of the issue, just submit an adress for we could send it to you...
Tomas Krajca
#1279
I've just now started working on a script module for that. With the new DynamicSprite.CreateFromScreenShot it's doable without dummy rooms.
My prototype looks promising, just a few minor things to fix. Watch this space.

Edit: Module now available here.
#1280
I originally wrote this to complement the CharacterControl script module so I thought I might as well post it here:

My CharacterRegionSounds script module for AGS v2.7 and up

This script module simplifies the process of giving ALL characters different footstep sounds for different surfaces like wood, concrete or grass.

Features:

* Different sounds on different regions for all characters
* Automatic volume scaling

It works very well in combination with the CharacterControl script module.
Any feedback appreciated.

Download v0.80b here
Mirror v0.80b (Thanks Candle!)

This download includes the script module and documentation.
SMF spam blocked by CleanTalk