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

Topics - Alynn

#81
Beginners' Technical Questions / Process Click
Thu 08/01/2004 13:51:37
And here is my process_click
Code: ags

function on_mouse_click(int button) {
  // called when a mouse button is clicked. button is either LEFT or RIGHT
  if (IsGamePaused() == 1) {
    // Game is paused, so do nothing (ie. don't allow mouse click)
  }
  else if (button==LEFT) {
    if ((GetCursorMode()==0) && (GetHotspotAt(mouse.x, mouse.y) == 0)){
      MoveCharacter(0, GetViewportX()+mouse.x, GetViewportY()+mouse.y);
    }
    else {
      ProcessClick(mouse.x, mouse.y, GetCursorMode());
    }
  }
  else {   // right-click, so cycle cursor
    if ((character[0].room != 1) || (IsGUIOn(4)==1)){
      SetNextCursorMode();
    }
  }
}


The part I'm most concerned with is the button==LEFT code block The first part checks if it is in walk mode, that worked fine unless the hotspot reacted to walking (like walking between the upstairs and downstairs floors on a certain room). So, I added the second part which checks if the mouse is over a hotspot. The downside to doing it this way is by clicking walk on anything that is a hotspot and no interaction for it, it does nothing.

I've tried different ways, but nothing seems to give me the best of both worlds (unless I really want to add a moveCharacter command to EVERY hotspot, which I really don't want to).

Just putting this out there in case anyone else can think of something that I haven't already :)
#82
General Discussion / BEST JOKE EVER!!!!
Thu 25/12/2003 04:04:13
LOLOLOLOLOL open AGSEDIT on December 25th

Be merry... cuz im LMFAO.

CJ a hell of a funny guy :)
#83
Code: ags
function FaceDirection(int ch, int d) {
  if (d == F_UP){ //line number 21
    FaceLocation(ch, character[ch].x, character[ch].y-10);
  }
  else if (d == F_LEFT){
    FaceLocation(ch, character[ch].x - 10, character[ch].y);
  }
  else if (d == F_DOWN){
    FaceLocation(ch, character[ch].x, character[ch].y+10);
  }
  else if (d == F_RIGHT){
    FaceLocation(ch, character[ch].x + 10, character[ch].y);
  }
}


all the F_ vars are defined in the header

#define F_UP 0;
#define F_LEFT 1;
#define F_DOWN 2;
#define F_RIGHT 3;

//import function FaceDirection(int ch, int d);

I tried to use the import in the script header but it didnt work so i commented it out. Anyway...

When I try to save it I get the following error:

Error (Line 21) : Parse Error in expr near '0'

my brain isnt working or something...

Thanks,
#84
Advanced Technical Forum / Midi lag
Wed 24/12/2003 14:44:29
All of my music is midi, and it plays and does everything it is supposed to with no problems, except when Display or DisplayMessage is used, then you can here a difinate lag in the midis.

I'm running 2.6 on a P4 2GHz, at 16-bit color 320X240, I even double checked and removed all the old plugins I was thinking about using (Snowrain and flashlight) and it still lags.

The room itself has 16 hotspots 3 and 3 objects.

Maybe I just have too much in the room (although in other rooms I notice the lag there too which has much less).

Thanks.


PS In addition, what the hell is the escape character to use quotes in a string? I used any and everything I have ever used in coding and nothing worked, I RTFM and didn't find it either (may have been looking in the wrong place). Anyway thanks again.
#85
I'mma using the 2.6 I've already changed my palete (even started a new game and changed the pallete) Anytime I try to import my 32 bit rooms it gives me an error That I need to check the filename or bit depth (must be an 8 or 16 bit image)

could someone shed some light on this?
#86
Ok, I have to have this option turned on for a few special movements (like when the character walks from the first to the second floor in my first room). Walking is accomplished with this script
Code: ags
if (GetCursorMode()==0){
      MoveCharacter(0, mouse.x, mouse.y);
    }
    else {
      ProcessClick(mouse.x, mouse.y, GetCursorMode());
    }


This works except for my scrolling rooms, which he will only walk so far into the screen (im assuming at 240 pixels) is there a way to turn that off for some rooms, or anyone know of a better work around than what I am using?

Thanks.
#87
Critics' Lounge / C&C For first 3 backgrounds
Thu 18/12/2003 13:59:21
Ok, I have the first 3 backgrounds for my game finished the first 2 I will display the third one is larger (scrolling) so I'll post a link




and the link HERERERERE!!
#88
Hints & Tips / Odyssius Kent
Wed 17/12/2003 15:55:51
Ok, I have no idea what to do next...

Spoiler
I have already gotten the flower, what I have in inv is a dress, shovel, treasure map, toupe, wooden cross, list of items, I think thats it...

I have already put the thorn in the blowup doll, the dude in the hallway wont talk to me, I cant get a video card, I have tried using inventory on everyone and everything, still nothing... Anyone give me a nudge in the right direction?
[close]

Thanks...

EDIT: Oops I didnt see the other thread on this :(
#89
I have a simple interatction with one of my inventory items you first get A pet rock (inv item 1) and Yorrik (inv item 2) both for all intents and purposes are the exact same item. When you look at the pet rock this code executes:

Code: ags
  DisplaySpeech(0, "This is my pet rock, Yorrik.");
  DisplaySpeech(0, "Doesn't he have the cutest little smile?");  
  LoseInventory(1);
  AddInventory(2);


This works, normally, now the petrock is named Yorrik which has similar code without the Add and Lose inventory lines... The strange behavior is when the PC is near the right side of the screen. on the first line where it should say "This is my pet rock, Yorrik. all you see is the period and nothing else, while the second line displays normally...

Any idea why this is doing it

This is version 2.56d (waiting patiently for the 2.6 release version to be finalized ;))

Anyway thanks in advance.
#90
This isn't huge, but it would be a nice feature for some people (me included).

Basicly when importing sprites it automaticly numbers the sprites with the lowest number available and then numbers the rest (if you did a multiple import) after that. I like to keep a certain numbering scheme (100-199 is main char sprites, 200-299 is another character, 0-50 are inventory items and 51-99 are their corrisponding cursor icons). But when I import the sprite sheets I would like to specifiy what numbers I want them to be instead of manually having to go in and change each number before I use them. When you are importing a sprite sheet with all character animations and it has 50 sprites on it, it takes quite awhile to renumber all of those, I would rather import the sprite sheet and tell the program start numbering from number 200 and go from there. Of course it would have to check if the number of sprites its importing overwrites any existing sprites in the folder. I leave it up to CJ how he wants to do that.....

Anyway just a suggestion :)
#91
Maybe I'm totally messed up but....

I have a room, on the color count for the room it shows 253 colors, however when I import the background into AGS it says I have too many colors 253 colors shouldnt be too much in a high color game... For an experiment I started a new game with 8 bit color and imported the room (default 8 bit pallate with no changes) and I recieved the same error, and the room imported and looked the exact same as in high color...

Exact pallate turns all my colors all funky in both modes...

Also, when I was looking through the color numbers in the editor I noticed that by adjusting the blue you get the color numbers 0-31, however when trying to find the next lowest number, it is 64... what happened to colors 32-63, I also noticed the sliders only go up to 31 while in 8-bit the sliders go to 63...

Anyway... just wanting an explination, reason, workaround for my background problem, and what is the deal with the pallate (IE do I have to know all the colors that AGS uses in high color and match them or the background wont import properly or what)
#92
I have that line of code in a any click interaction on a hotspot.

I have a 2 floor room with a stairwell I made sure it worked on any interaction with the hotspot I then added the ifcheck to make it only fire on walk... BUT it does fire. It just walks to the nearest place on the first floor...

Is there anyway to counter this?
#93
Advanced Technical Forum / zoooOOOOOOOOM!
Tue 18/11/2003 18:40:31
There are a few places on my game where a player will be behind some very fine lined areas (banisters, chainlink fences), and making sure everything lis lined up correct for my walkbehinds is no less than a headache...

Would it be possible to add a zoom view to the room editor, so we can get those details perfect?
#94
I have been looking all over and I cant seem to find what I am looking for... I am trying to help out the host of my webpage with a download counter for my programs I have hosted on his site, I have found one that basicly works, but is very ugly IMO (seperate dl page).

What I want is a real time counter that when the download link is pressed the download starts and the counter is updated in real time on the displayed page.

Does anyone have, or know where I can get such a tool, withing my price range (from 0.00 to 0.00).

Thanks.
#95
You think maybe you could place this in here... so many if statements gets on my nerves...

(using psudocode)
Code: ags
switch (inventory_Number){
    case 1: {Witty remark}
    case 2: {Smartass remark}
    case 3: {Correct item do stuff}
    case 4: {Make fun of the player for thinking that}
    case 5: {Kill the player (never use a fork on an electrical outlet)
    default: {Throw random gibberish on the screen}
}


So much nicer IMO... many if statements work the same, just not as easy to maintain... (would be nice if it would work for strings also)
#96
Ok... I started simple... then after looking at it... I decided to go a whole new direction... so anyway here is my first attempt at doing the house of the main char (mostly a test of things using a simple editing tool)

Now the second one that I used GraphicsGale on (after I learned how to use it in a decent manner) with me doing pretty much all the graphics (the floor and wall patterns aren't mine). I know its not complete but I want an opinion on my progress...


What do you think? Better, worse???? Personally I think its much better...
#97
How hard would it be to implement the auto code complete for installed plugins, IE the editor would read the DLL and load the script funcions into its database of functions (I dunno exactly how you have that setup so forgive me if I am completely wrong) so that when typing out the script the auto complete dropdown appears for those functions as well as the core functions...
#98
Hello ladies and germs...

I have been working a bit on my art and what not for my first AGS game... since I am pretty new to the scene could you please check out

http://groups.msn.com/fostoria/skytowerrescue.msnw?Page=Last And check out the one screenshot and the other straight rooms I have worked on...

Would you, but graphics value alone, say these are ok, The house one is just an experiment I actually have one that takes all my best ideas from this room, this one just shows the poster and the computer (and desk)...

Secondly... My main sprite is about 18 pixels wide and 24 pixels tall... is that too small for these size rooms? and items...

The graphics are basicly being pulled from my RM2K games and the RTP and what not... Anyway... just wondering....

* Alynn prepares to be flamed like a BK whopper....
#99
Currently I am using IDraw for my graphics, and it gets the job done... But with only 256 colors to work with and its impossible to tone up and or down the color depth... Would it be worth shelling out the money for one of these programs? I'm not the worlds greatest computer artist, but with AGS its mostly perspective drawing which I'm fairly good at...

So anyway... is it worth it?
#100
Out of curiosity, and before I spend hours trying to figure it out for myself...

If you have a global room variable, and you leave that room, is the script that runs that room destroyed and the variable reinitialized when the room is re-entered, or do I need to make those variables in the global script so they will not be destroyed?

Personal preference has always been to make the scope of any variable in the lowest possible block of code, but if the room object (sorry I'm mostly a java programmer) is left is that room object destroyed until the room is reentered, and so reinitializing my global room variables?
SMF spam blocked by CleanTalk