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

#2541
Told you I'd enter, eventually.
It's a bit of a long 'un, I got a little carried away.
 
Items:
  From List:
    * C.S.I Season 1.1 Boxset (Any kind of DVD - Mats Berglinn)
      A tie (Mats)
    * A big bag of Salt'n'Vinegar crisps (Chips (any flavor) - Mats again)
    * pecan nuts (You guessed it)
    * Breadjuice: all the goodness of bread in a softdrink! (Layabout)

  Added:
      Bleach
    * Dishwasher Tablets
      Sleeping pills

Ashen   in   'The Bank Job'
'hall'
USE crisps, nuts and Breadjuice on self
  ASHEN: "What? I'm a nervous eater."
LOOK ROBBER1
  ASHEN: "It's a man with a gun, and a sock over his head."
  ASHEN: "Unlike the others, he's not wearing gloves. He has very clean hands for a criminal."
LOOK ROBBER2
  ASHEN: "It's a man with a gun, and a sock over his head."
  ASHEN: "His heart doesn't really seem to be in this, he seems a bit listless."
LOOK ROBBER3
  ASHEN: "This guy seems to be the leader. The sock over his head looks cleaner than the others."
  ASHEN: I'm not too sure what that is he's holding...."
TALK ROBBER3
  ASHEN: "What kind of a weapon is that?"
  ROBBER3: "In this hand, I hold the Sun. In this, a magnifying glass with which to focus it's rays."
  ROBBER: "Now sit down before I burn you."
  ASHEN: "Fair enough."
TALK ROBBER1
  ASHEN: "Can I use the bathroom, please?"
  ROBBER1: "Well... alright. Nobody else move!"
  GOTO ROOM Bathroom
 
Bathroom

LOOK sink
  ASHEN: "It's a sink, with soap for washing your hands."
LOOK soap
  ASHEN: "It's a bar of soap. Quite a nice one, as soaps go."
LOOK soap dispenser
  ASHEN: "I wonder why they have soap, AND a soap dispenser?"
LOOK toilet
  ASHEN: "It's a toilet."
LOOK bleach
  ASHEN: "It's a bottle of bleach, probably for cleaning the toilet."
USE bleach
  If there's space in inventory, TAKE bleach
  ASHEN: OK
USE bleach ON soap dispenser
  animation: close-up as ASHEN pours bleach into dispenser
  ASHEN: "Glug glug glug!"
USE diswasher tablets ON soap dispenser
  animation: close up on ASHEN dropping a tablet into the dispenser
  animation: close-up of dispenser starting to fizz.
  ASHEN: "Oooh! Bubbles!"
  ASHEN: "Man, that smells BAD."
USE toilet
  animation: ASHEN flushes the toilet, ROBBER1 opens door.
  ROBBER1: "Finished?"
  animation: ASHEN tries to leave bathroom
  ROBBER1: "What? Without washing your hands? You filthy little git."
  animation: ASHEN uses the soap, and leaves. ROBBER1 uses the dispenser to wash hands, covering them in foaming, corrosive goo.
  animation: ROBBER1's hands start to melt, and he runs away, screaming.
  ASHEN: "It worked! YES! I am SO MacGuyver."


CUTSCENE outside:
ROBBER1 is let out of the bank to get medical attention, along with some hostages.
 

Back in 'hall'

  ASHEN: "Oh well, 1 down, 2 to go."
TALK ROBBER2
  ASHEN: "Hello."
  ROBBER2: "Uh."
  ASHEN: "Look, if you're going to hold us hostage, at least have the manners to look like you're enjoying it."
  ROBBER2: "To tell you the truth I'd rather've stayed at home."
  ASHEN: "..."
  ASHEN: "YOU'D rather be at home? How d'you think we feel?"
Use CSI DVD on ROBBER2
  ASHEN: "Are you sure you want to rob this bank? Wouldn't you rather watch CSI?"
  ROBBER2: "Which one?"
  ASHEN: "Vegas."
  ROBBER2: "Meh. I prefer Miami."
  ASHEN: "I can't get into that as much, I think it's David Caruso's fault."
  ASHEN: "He scares me, with his black, beetle eyes, and his tiny liars mouth."
  ROBBER2: "..."
  ROBBER2: "What?"
  ASHEN: "The lead guy in it. Horatio Caine? He has a tiny, puckered mouth that disturbs me a little."
  ROBBER2: "Can't say as I've noticed."
  ASHEN: "Lucky you."
  animation: ROBBER3 comes over
  ROBBER3: "Alright, alright, break it up."
  ROBBER3 turns to ASHEN
  ROBBER3: "You, sit down."
  ROBBER3 turns to ROBBER2
  ROBBER3: "And you, keep your gun up and your mouth shut."
  WAIT 1 or 2 seconds
  After timer expires:
    ROBBER2: "No, that's really bugging me now. You..."
    ROBBER2 turns to MANAGER
    ROBBER2: "You got the internet in your office?"
    MANAGER: "Er... Yes?"
    ROBBER2 turns to ASHEN
    ROBBER2: "Right, you, come with me."
    GOTO ROOM Manager's Office
 

Manager's Office

Enter room:
  ROBBER2: "Right, to the Internet Movie database!"
  animation: ROBBER2 walks over to computer, sits down and becomes ingrossed.
LOOK at desk.
    ASHEN: "I do enjoy rummaging around in other people's drawers."
    ASHEN: "..."
    ASHEN: "You know what I mean."
    animation: ASHEN searches desk drawers
    ASHEN: "Well, well, well. What have we here...?"
    ADD INVENTORY (sleeping pills)
LOOK at coffee machine
  ASHEN: "Mmm. I could just go for a cup about now."
  ROBBER2: "I'll have one, if you're making some."
USE coffee machine
  animation: perculation
  ASHEN: "Cream & sugar?"
  ROBBER2: "No thanks."
  animation: ASHEN puts coffee mug next to ROBBER2
USE sleeping pills on coffee.
  animation: ASHEN drugs the coffee.
  ASHEN: "You know, the caffine might interfere with the tablets..."
  animation: ASHEN tips more tablets into coffee.
  animation: ROBBER2 takes a sip of coffee, and falls face down asleep on the

desk.
  ASHEN: "That was pretty strong coffee, I should probably tie him up before he

comes to."
LOOK at door.
  ASHEN: "There's a suit-bag hanging on it. I guess the manager must've brought a

change of clothes to work."
USE suit-bag
  animation: ASHEN crosses to door, un-zips the bag and reaches in.
  ASHEN: "Ah-ha! A tie!"
  ADD INVENTORY (tie)
USE tie on ROBBER2
  ASHEN: "Don't know if it'll hold, but it'll do for now.
USE door.
  ASHEN: "I can't go out there, one of them is still around."
USE tied-up robber.
  animation: ASHEN gives the trussed up ROBBER2 a push, sending him halfway across the office.
  ASHEN: "Hmm..."
USE tied-up robber (again)
  animation: ASHEN takes a run up, and gives the trussed up ROBBER2 another push, sending him flying through the door, and into ROBBER3 in the hall outside.


VICTORY CUTSCENE:
Back to 'hall', again
  animation: ASHEN strides truimphantly out of the Manager's Office, to meet his adoring public. Unfortunately, ROBBER3 is back on his feet, and clobbers our hero on the back of the head.
  ROBBER3: "Right, I didn't want to have to do this, but you've left me no choice."
  ROBBER3: "BEHOLD THE AWESOME DESTRUCTIVE POWER OF THE SUN!"
  animation: ROBBER3 brandishes his sun/magnifying glass combo weapon
  ASHEN: "..."
  ASHEN: "That's not the Sun. It's a cabbage painted gold."
  ROBBER3: "..."
  ASHEN: "It's not even proper gold, it's just a very bright yellow."
  ROBBER3: "..."
  ROBBER3: "Balls."
  animation: POLICE storm the building, ROBBER2 and ROBBER3 are taken into custody

EPILOGUE
  ASHEN became something of a local celebrity until, six months later, he told the story of 'How I Defeated Three Armed Bank Robbers All By Myself' once too often, and had the everloving crap beaten out of him.

The moral of this story? No-one likes a smart arse.
#2542
It's a movie. At least, it's the intro to a movie, made to look like a game by a games company, using the same technology as their games. That's my understanding, anyway. What the rest of the movie is like is anyones guess.
#2543
Line 89 (   if(button==5)) is missing a {, so line 90 effectively closes interface_click, giving the error. Add the { to line 89, and it should be OK.

Also, if there's only one line, you don't actually need the braces:
Code: ags


function interface_click(int interface, int button) {
  if (interface == GUI1) {   
    if (button == 1) SetCursorMode(MODE_LOOK);
    if (button == 2) SetCursorMode(MODE_USE);
    // Etc
    }
  if (interface== Q) {
    //etc
  }
}

Would work just as well.
#2544
Isn't it "He-Man & The Masters of the Universe", the '&' implying he's not one of them himself?
EDIT: I realise it could be 'He-Man and the Other Masters of the Universe', it just seems that he does a bit too much actual work to be a Master. But, then, 'He-Man - Dogsbody of the Universe' doesn't have quite the same ring to it, I admit.

Also, to stay on topic, 'ASH' (as in Evil Dead) was the name I used to use on arcade high-score tables, which only needed 3 letters. Since most 'net things need a name of 5 or more characters I added the N from my real name, and ASH-N became Ashen, as that's a real word, and sounded cool at the time.
#2545
You could create a 'dummy' character (or use an NPC if you'd rather), copy EGO's inventory to them before clearing the inventory, then restore from it when you want. Something like your loop could be used:
Code: ags

// to backup inv
i=0;
while (i<NoOfItems) {
  if (character[EGO].inv[i] == 1) { // if EGO has that item
    AddInventoryToCharacter (DUMMY, i); // Copy it over
    LoseInventory(i); // Then lose it
  }
  i ++; // Move on to next item
}

//to restore
i=0;
while (i<NoOfItems) {
  if (character[DUMMY].inv[i] == 1) { // if DUMMY has that item
    LoseInventoryFromCharacter (DUMMY, i); // Copy it back
    AddInventory(i); // Then lose it
  }
  i ++; // Move on to next item
}
#2546
Critics' Lounge / Re: hurray! I drew a sheep!
Wed 30/03/2005 18:35:29
I thought it was Kiwis and the Welsh that had that reputation, not Aussies.

It's nice an' all, and it does look quite sheep-like, but there's something about it - the black outlines, the shape of the neck, the colouring, the fact that the 'wool' is perfectly smooth, some combination of these - that makes it look, to me, like a Llama covered in custard.

Maybe un-smooth the shading a little, to make it look more wooly.
#2547
You can fade text overlays? How? (I've propbably missed something obvious, I know..)

Couldn't you put your text on a GUI, and fade that in/out?
#2548
Rave:
Hope you don't mind, but I've been doing some tinkering with this. I got to thinking, "How would I do that? Oh, I could use... But then, how would I ... Well that might work...But what about..."
Then I couldn't sleep to well a couple of nights, and decided to do some scripting. Now I have a 80-something% complete (I think) journal program, made in AGS.
But, I'm sleeping a little better, and I'm not sure if I have the momentum to finish it, without encouragement.

So, if people could let me know what they think - is it worth finishing? Would anyone be interested in the code? (Which is probably pointlessy over-complicated but, hey, it works.)

AGS JOURNAL - 0.5 BETA by Ashen
Known Bugs:
- Random Text
     Sometimes, after a line change, it inserts random characters instead of your text. I don't know why, unless it 'combines' the keycodes of the last 2/3 characters, and displays that?
- ?
     I'm sure there's more. I've been very lazy in my testing.


To Be Completed:
- Infinite Password Loop
     There's a password system, and it works OK. But, entering the wrong password brings up a 'Re-type Password' prompt. Entering the wrong password there brings up another, then another, then another, etc, 'till you enter the right password or alt-x. I just need an int to limit the number of times this happens, before you get booted back to menu screen.
- Game Stuff
     Most of the game-specific stuff (change mode on right click, on_key_press shortcuts, etc) needs to be changed or removed.
- Cancel Option on 'Select/Add User' GUI
     Pretty self-explanatory, especially after you've tried the thing.
- 'Edit Entry' Function.
     Not so much for completed entries (e.g. to remove embarassing, drunken rambling), just to correct more than the current line of the entry being written. I've an idea how to do this, but so far it's not working and - as I said - I'm kind of running out of steam on the project.
- Different Fonts
     I agree with Peter about cursive fonts being a bit pants, but the default AGS font isn't very nice either. An option to choose between 2 or 3 fonts would be nice, and shouldn't be too hard.
- Make Less Sucky
     I've been working on the "just get the bloody thing working" principle, so some of the GUI layouts and prompts could be better done. Likewise, there're some graphics in there, but there's still a lot of default buttons,  Display boxes, and InputBox-es that could stand sprucing up.
- ?
     There's probably more I haven't thought of. This is, after all, an early Beta release - more of a tech demo, in fact.
#2549
I think it means 5 items from the 'Hasn't been an inventory item yet' thread, but only from 2 posts.
E.g. you could have
  A comic-book            (Mats Berglinn)
  A rubber-ducky          (Mats Berglinn)
  A voodoo-mask           (Mats Berglinn)
  canned peas             (Jimi)
  an electric floor waxer (Jimi)

but not:
  A rubber-ducky          (Mats Berglinn)
  A voodoo-mask           (Mats Berglinn)
  canned peas             (Jimi)
  an electric floor waxer (Jimi)
  Captian Mostly's mum    (Captain Mostly).

Not that that's much less confusing, I'll grant you.

I've missed the last few Puzzletime's, largely due to being a lazy git, but I fully intend to enter this one, oh yes.
Just not for a few days.

Also, 18:00 in what time zone? It might be better to post nearer the time with "24 hours from the time of this post".
#2550
on_event can go pretty much anywhere in the global script, but if you want to play safe, put it somewhere before interface_click. (Unless you've already got on_click somewhere, of course.)
And, uh, I don't understand. What code have you got that would make it need changing? With on_event, when event is GUIMDOWN (or GUI_MUP, I think), data is the gui the mouse is over, so the code as-is will close whatever GUI the right button is clicked on. What else do you need?
#2551
Oh, sure, if you want to do it the easy way.... ;)

Code: ags

function on_event (int event, int data) {
  if (event == GUI_MDOWN) { // Mouse button pressed
    if (IsButtonDown (RIGHT)) {
    GUIOff (data);
    return;
    }
  }
}

Does seem to work, yes.
#2552
Add 1 pixel to the left of the image, and set that to a colour that isn't otherwise used in the image. (You could also add the extra pixel to the right, and select 'Top Right Pixel' for the Transparent colour.) Then, when you import the image either select everything but that line, or use 'Grab whole image' and then 'Crop Sprite Edges' in the Sprite manager (might've been renamed for 2.7, but it should still be there) to remove the transparent line.
For the 'Border' image, use black for the extra pixel, since that's the colour you want not to show up.
#2553
Have you tried on_event, and GUI_MUP/DOWN? E.g.
Code: ags

int press;


function on_event (int event, int data) {
  if (event == GUI_MDOWN) { // Mouse button pressed
    if (IsButtonDown (RIGHT)) press = 1;
  }
  if (event == GUI_MUP) { // Mouse button released
    if (press == 1) GUIOff (data); // If it was RIGHT, turn of the GUI. 
    press = 0;
  }
}


However, if you right click on a GUI button, it runs the button script before closing the GUI, don't know if that's a problem.
#2554
1. To make global responses, add them to the interface_click command for the PARSER GUI. Should look something like:
Code: ags

if (interface == PARSER) {
  GetTextBoxText(PARSER,0,input); //This gathers the text from the text-box in GUI 0, and from Object1 and to store it in the predefined string "input"
  ParseText(input);

  if (Said("kill self")) { 
    Display("GAME OVER"); QuitGame(0); 
  }
  else if (Said("eat self")) { 
    Display("As you begin to devour your shoe you get a strange feeling that this may be quite hazzardous");
  }
  //Add more 'else if's for other responses
  CallRoomScript(1);
  SetTextBoxText(PARSER,0,""); 
}


2. Parser doesn't work in new rooms.
Have you added the on_call function to the new room's script? You need to add that to every room, to handle the room-specific responses to input.
#2555
Damn, forgot about that! Always happens when I post something without testing it.

Maybe use a third string, and StrFormat?
Code: ags

string newtext;
StrFormat (newtext "%s %s", labeltext, mouseover);


Or, use a variable to see if it's been set:
Code: ags

//create an int
int settext;


// Where you're setting the label text at the moment
StrFormat (labeltext, "Use ");
settext = 0; // reset int, so labeltext can update



// Then, in rep_ex
if (settext == 0) { // if labeltext hasn't been changed
  StrCat (labeltext, mouseover); // add the mouseover string to the end of labeltext
  settext = 1; // mark labeltext as changed
}
SetLabelText (GUI, LABEL, labeltext);
#2556
(Bah! Ishmael beat me to it. Oh, well, might as well post anyway...)
What exactly are you asking? 'How to make an inventory' could cover a lot of ground.....

Every character has an inventory by default, you just have to add things to it using AddInventory (item) or AddInventoryToCharacter (character, item).

To make a new Inventory item, use the 'New Item...' button on the 'Inventory items' window of the editor.

To change the way the Inventory looks in game, make a new GUI, or edit the one that's already there. You'll also have to change the script a little to make it use that GUI, this post explains that.

Try doing a forum search for 'inventory GUI', or 'custom inventory' for other replies, tutorials, etc. Aslo, have a look at what the manual and the BFAQ have to say about inventories, and GUIs in general.
#2557
What code are you using?
#2558
Yeah, just set the 'mouseover' string to @OVERHOTSPOT@, and it should be fine. (Again, if I'm understanding what you want.)
#2559
I don't think you can the label text directly (although it'd probably be useful).

Since you've deleted your first post, I'm not totally sure what you're trying to do, but I think you'll have to set a string instead of the label text, then set the label text itself it rep_ex. (Rather than setting the text directly, then changing it in rep_ex.) E.g.:

Code: ags

// Where you're setting the label text at tthe moment
StrFormat (labeltext, "Use ");
//instead of SetLabelText (GUI, LABEL, "Use ");



// Then, in rep_ex
StrCat (labeltext, mouseover); // add the mouseover string to the end of labeltext
SetLabelText (GUI, LABEL, labeltext);


(Sorry if this doesn't make sense, but as I said I'm not too clear on what you're after.)
#2560
You'd need to use GetTextWidth (string, font), SetGuiObjectSize (gui, obj, width, height), and SetGUIObjectPosition (gui, obj, x, y), e.g (something like):

Code: ags

// Label0 is the label to be changed, at position 5, 5
//Label1 is the label to be moved.
int width = GetTextWidth (text, 0); // where 'text' is the contents of Label0, change font number as needed
int height = GetTextHeight (text, 0, width); // not be needed, if labels will have a fixed height
SetGUIObjectSize (GUI, 0, width, height); // change size of Label0 to fit text 
SetGUIObjectPosition (GUI, 1, 5 + width, 5); // move Label1 to position

(You might have to make it int width = GetTextWidth (text, 0) + 1; (and height + 1, as well) to make it fit properly.)

But, wouldn't it be easier to just combine them into a single string?
SMF spam blocked by CleanTalk