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

#161
Eeee! Thanks for all the help, everyone. I'm not able to respond in detail or try stuff out right now because I'm rushing off to school, but I really like KhrisMUC's paintover.  :D 

I'll try to edit this post later with an updated pic.
#162
Hey, there. I'm working on a background for No Traveller Returns, and I've run into another hair-tearing problem.

The background is far from finished, but the issue at hand is that I'm wanting the lights on the ceiling to be domes, swelling downward toward the floor. Nothing I've tried so far seems to give the appearance of contour. Any help would be greatly appreciated.








x2
#163
Aside from its being a paintover of Mr Colossal's example walk cycle, is there any particular reason that the pixels are doubled all over except for the eyebrows? Which size did you want him to be?

I would personally recommend going 320x200 if you're not comfortable with your artistic skills. Fewer pixels = less hair pulling, usually.
#164
You guys were right; it didn't work with on_mouse_click, no matter how I ordered the code.

I used on_event and got it working, though. Thanks, Alynn and Ashen. You've saved my bacon.  :)
#165
Hey guys. Thanks for the responses. I tried reordering things, and it compiles, but now it doesn't register any clicks while the inventory GUI is up, although it works fine when it's not. The code I've got is:

Code: ags
#sectionstart on_mouse_clickÃ,  // DO NOT EDIT OR REMOVE THIS LINE
function on_mouse_click(MouseButton button) {
Ã,  // called when a mouse button is clicked. button is either LEFT or RIGHT
Ã,  
Ã,  if (gInventory.Visible == true) {


Ã,  Ã,  if (IsGamePaused() == 1) {
Ã,  Ã,  // Game is paused, so do nothing (ie. don't allow mouse click)
}
Ã,  Ã,  else {
 
Ã,  Ã,  Ã,  if ((button == eMouseRight) &&Ã,  (Mouse.Mode == eModeLookat)) {
Ã,  Ã,  Ã,  Ã,  mouse.Mode = eModeInteract;
Ã,  Ã,  Ã,  Ã,  mouse.UseModeGraphic(eModePointer);
}Ã,  Ã,  
Ã,  Ã,  Ã,  else if ((button == eMouseRight) && (Mouse.Mode == eModeUseinv)) {
Ã,  Ã,  Ã,  Ã, mouse.Mode = eModeLookat;
}
Ã,  Ã,  Ã,  else if ((button == eMouseRight) &&Ã,  (Mouse.Mode == eModeInteract)) {
Ã,  Ã,  Ã,  Ã, mouse.Mode = eModeLookat;
}
Ã,  Ã,  Ã,  else if ((button == eMouseLeftInv) && (Mouse.Mode == eModeInteract)) { 
Ã,  Ã,  Ã,  Ã, player.ActiveInventory=InventoryItem.GetAtScreenXY(mouse.x, mouse.y);
Ã,  Ã,  Ã,  Ã, Mouse.Mode=eModeUseinv;
}
Ã,  Ã,  Ã,  else if ((button == eMouseLeftInv) && (Mouse.Mode == eModeLookat)) { 
Ã,  Ã,  Ã,  Ã, inventory[game.inv_activated].RunInteraction(mouse.Mode);
}
Ã,  Ã,  Ã,  else if ((button == eMouseLeftInv) && (Mouse.Mode == eModeUseinv)) {
Ã,  Ã,  Ã,  Ã, inventory[game.inv_activated].RunInteraction(mouse.Mode);
Ã,  
}
}
}
Ã,  else {
Ã,  Ã,  
Ã,  Ã,  if (button == eMouseLeft) {
Ã,  Ã,  Ã,  Ã,  ProcessClick(mouse.x, mouse.y, mouse.Mode );
Ã,  }
Ã,  Ã, 
Ã,  Ã,  else if (button == eMouseRight) {Ã,  Ã, // right-click, so cycle cursor
Ã,  Ã,  Ã,  mouse.SelectNextMode();
Ã,  }Ã,  
Ã,  Ã,  else { 
Ã,  }
Ã,  }



Ã,  } 


#sectionend on_mouse_clickÃ,  // DO NOT EDIT OR REMOVE THIS LINE



I'm going to look carefully at the link Ashen posted but I guess I'm dragging my feet a little bit because it means starting over with my whole inventory arrangement, it seems.  :-\

But it may come to that, unless there's something obvious that I'm missing or have messed up on in the code above.
#166
Hey.

I'm trying to set up my custom inventory the way I want it, but I've run into problems when it comes to trying to allow the player to cycle through cursors while the inventory is up.

It seems that using button == eMouseRightInv only registers a click if the mouse is actually over an inventory item (so nothing happens if the inventory is empty, or if the click takes place in an empty portion). However, I can't seem to get button == eMouseRight to work at all while the inventory is up. Here's the code I'm trying to use:

Code: ags

#sectionstart on_mouse_clickÃ,  // DO NOT EDIT OR REMOVE THIS LINE
function on_mouse_click(MouseButton 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)
}

Ã,  Ã, if (button == eMouseLeft) {
Ã,  Ã,  ProcessClick(mouse.x, mouse.y, mouse.Mode );
Ã,  }
Ã,  else if ((button == eMouseRight) && (gInventory.Visible == false)){Ã,  Ã, // right-click, so cycle cursor
Ã,  Ã,  mouse.SelectNextMode();
Ã,  }Ã,  
Ã,  Ã,  else if ((button == eMouseRight) && (gInventory.Visible == true) &&Ã,  (Mouse.Mode == eModeLookat)) {
Ã,  Ã,  mouse.Mode = eModeInteract;
Ã,  Ã,  mouse.UseModeGraphic(eModePointer);
}Ã,  Ã,  
Ã,  else if ((button == eMouseRight) && (gInventory.Visible == true) &&Ã,  (Mouse.Mode == eModeUseinv)) {
Ã,  Ã,  mouse.Mode = eModeLookat;
}
Ã,  else if ((button == eMouseRight) && (gInventory.Visible == true) &&Ã,  (Mouse.Mode == eModeInteract)) {
Ã,  Ã,  mouse.Mode = eModeLookat;
}
 else if ((button == eMouseLeftInv) && (Mouse.Mode == eModeInteract)) { 
Ã,  player.ActiveInventory=InventoryItem.GetAtScreenXY(mouse.x, mouse.y);
Ã,  Mouse.Mode=eModeUseinv;
}
 else if ((button == eMouseLeftInv) && (Mouse.Mode == eModeLookat)) { 
Ã,  inventory[game.inv_activated].RunInteraction(mouse.Mode);
}
 else if ((button == eMouseLeftInv) && (Mouse.Mode == eModeUseinv)) {
Ã,  inventory[game.inv_activated].RunInteraction(mouse.Mode);
Ã,  
}
}


#sectionend on_mouse_clickÃ,  // DO NOT EDIT OR REMOVE THIS LINE


The left inventory code works fine, but nothing happens when I right-click while the inventory window is up. Although button == eMouseRightInv works, I'm not satisfied with only being able to cycle cursors while the mouse is over an inventory item. I want the player to be able to cycle no matter where their cursor is on the screen.

I would appreciate any help.Ã,  :-\
#167
Critics' Lounge / Re: Joyce C Clump
Sun 30/07/2006 11:14:19
Hahaha. This is great, Mr_Frisby. I really enjoyed the subtlety of the humor. Heh heh this could be on its way to syndication.
#168
Quote from: SSH on Wed 26/07/2006 10:04:12
I notice in your code that you're changing invCustomInv.Height and invCustomInv.Width... don't you mean invCustomInv.ItemWidth and invCustomInv.ItemHeight?


Arrrgh.  :-[ 

You're right, of course. Thanks, SSH.
#169
Quote from: Gilbot V7000a on Wed 26/07/2006 06:13:05
Maybe you can try moving the UpdateInventory(); line below the width/height codes and above the gui visible line?

I thought that was a good idea, but it didn't work. :/

I think SSH may be right, but I'm going to hold out a little longer and see if anyone has any idea why it's behaving the way it is before I give up completely and just make another inventory window.
#170
Hey.

My PC has two inventories, which appear in the same inventory box, but at different times (handled when the player clicks the buttons associated with each set of items). The item categories are not anywhere near the same sizes, so I need to have two separate item height/width designations, imposed by clicking the same buttons on the icon bar.

I tried setting the ItemHeight and ItemWidth properties within the code that's performed as a result of the player clicking on the buttons to bring up the inventory window, but that seems to do very strange things like not show any items in one inventory set and only showing one in the other.

The code associated with the two buttons is as follows:

Code: ags
function btnIconInv_Click(GUIControl *control, MouseButton button) {
Ã,  

Ã,  CopyInventory(1, 12); //copy inventory
Ã,  UpdateInventory(); 
Ã,  invCustomInv.Height = 25;
Ã,  invCustomInv.Width = 30;
Ã,  gui[2].Visible = true; //open inventory 
Ã,  mouse.Mode = eModeInteract;
Ã,  mouse.UseModeGraphic(eModePointer);
Ã,  gIconbar.Visible = false;

}


The other one is identical, with the exception of having different variables called in CopyInventory();.

In the GUI editor I have the size of invCustomInv as 211x127 and item size as 120x18 (the size of the other set of inventory items).

If I take out the height/width code and just use the settings in the GUI editor, everything works. I'm confused.Ã,  :=

#171
Quote from: Oneway on Sun 23/07/2006 12:04:13
Pslim: Thanks. Not being a D&D player myself i tried to keep character stats as simple as possible.

I actually wasn't talking about D&D.  :=  I meant Rogue, the classic 1980s ASCII dungeon hack game for the PC, such as can be found in a java incarnation here. Since the original there have been a bazillion different variations, some with full color graphics and a point-and-click interface, and I would be tempted to count Krakox the Barbarian among them. The main difference between your game (and Krakox) and Roguelike games (as variations of Rogue are called) is that Rogue had a huge variety of classes, items, and possible activities.

As for whether that's a good or bad thing, I think it's entirely a matter of taste. Giving the player some choices wouldn't hurt, though, I think. Some people have pronounced preferences about what types of characters they like to play in dungeon hack games, and allowing for different people to approach the game in different ways might improve the possibility of pleasing random gamers.
#172
Sure. :)

The colors should be more different, so we can see the shapes better. And maybe think about making the background of the icon one simple color, so the shape will be easy to see.

Maybe something like this:




Or this:

#173
This is an interesting idea, and the interface works reasonably well.

You might consider having some kind of intro screen, or making the instructions happen using a blocking function like Display. It all just sort of starts and goes along at its own pace and if you had to scratch your nose or look away you'd have to start the whole thing over again.

Also, there are some spelling and usage errors, and at least one bug:

Spoiler
If you cast brake [which should be "break"] on the egg while it is in the air, but after removing the defense spell, you get the same "as you can see there is no damage to the egg" message, which doesn't make sense since you've removed its defense.
[close]

I like the sprite, but I found the icons representing the different spells difficult to make out. You might consider making the cyan line that represents the function contrast more with the icon background.

In any case, I will be looking forward to seeing how this all comes out. Will it be story driven, or mostly about solving puzzles using your various spells?

If you are interested, by the way, I would be more than happy to proofread your dialogue for English usage and spelling.
#174
Quote from: KhrisMUC on Thu 20/07/2006 23:10:17
Couldn't you just use invMain.CharacterToUse = cOne; / invMain.CharacterToUse = cTwo; directly before displaying invMain?

It's my understanding that all that does is show One's or Two's inventory, depending on which way you set it. In that case, no, because One still doesn't have any of the contents of Two's inventory on his person, so when I tell the game to set the active inventory to whatever he picked out of Two's box, I get a crash and an error saying One doesn't have that item.

At least, that's how I interpreted that command in the manual when I saw it. If that's not actually how it works I may have put myself through a lot of grueling awfulness for no reason. <g>
#175
Thanks KhrisMUC and strazer, for the comments, but I tried setting INV_MAX to 100, and using AGS_MAX_INV_ITEMS instead, and both gave the same error when the button was clicked.

QuoteOf course you can't copy an item that doesn't exist.

I found this to be a rather cryptic comment when I first read it, but then I realized that you might mean that I should set INV_MAX to the total number of inventory items I have currently defined... and it worked! So I just need to update this every time I define a new inventory item.

Thanks you guys!

And thanks to Scorporius, who probably won't read this! You're my hero!
#176
Hey there.

In my current game, there is only one main character, but I need him to have two inventories. Having the secondary inventory show up is no problem, and I have that all set up, but interaction is another thing altogether.

I'm handling inventory clicks in script. At the moment, if I click on an item in the secondary inventory (owned by an invisible character whose only function is to have this inventory), the game crashes with an error saying that my PC doesn't have the item, and refers to the line of the global script where I've told it to set the active inventory to what the player just clicked on.

There's an old thread from 2003 that deals with exactly this issue, and Scorporius posted what looks like a brilliant solution, but I can't get it to work.

He proposes having a separate character for Ego's main inventory AND for the secondary inventory, and to copy the contents of one or the other into Ego's actual coded inventory depending on which inventory set the player intends to bring up. The code he posted (with some changes due to AGS updates that I muddled through after many error messages) is as follows:

Code: ags
function CopyInventory(int CharID1, int CharID2) {Ã,  Ã, //Copy Inventory
int INV_MAX = 300;
int i=1;
while (i<INV_MAX) {
character[CharID1].InventoryQuantity[ i ] = character[CharID2].InventoryQuantity[ i ];
i++;
}
}


This, he says, will copy one character's inventory onto another's. Then you're supposed to call the following when you open the GUI associated with the inventory you want to use:

Code: ags
Ã,  CopyInventory(1, 12); //copy inventory
Ã,  UpdateInventory(); 
Ã,  gui[2].Visible = true; //open inventory 



It compiles, but when I push the button with the above code associated with it, I get a crash and an error that says "Character.InventoryQuantity: invalid inventory index."


Any help would be greatly appreciated. I've been at this all night.Ã,  :-X
#177
Wow, yet another game that I loved on my C64 being remade in AGS! I'm excited! The graphics look great.
#178
The coloring method I use is similar to what Ildu suggested, with the only differences being that I burn and dodge a lot of the highlights and shadows instead of painting them on. I also suggest that any time you have achieved with some portion what you wanted to you duplicate the layer and continue working with the duplicate instead of the original, but that could just be because I'm so incredibly anal retentive.  :=
#179
I dig the portrait. I'm sure it's just a matter of taste and if you like it, it's a good choice, right?

I'm looking forward to this game. I'm especially intrigued by the idea of having a persistent blood meter that can be increased by feeding from victims of the player's choosing via puzzles toward that end.Ã,  :D
#180
Just a note that when I unzipped the updated version, the period in the version number part of the name of the .scm file caused AGS to think 1 was the extension, so it wouldn't recognize the file type until I renamed it. Testing it out now. :)
SMF spam blocked by CleanTalk