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

#1
Was able to solve it myself.

After some digging in the manuals, it seems that AGS is actually calculating based on the height of the GUI bg and the inventory thumbnail height, if the item is added to the second line or not.

QuoteRowCount property (inv window)

readonly int InvWindow.RowCount;

Gets the number of rows that can be displayed within the inventory window. This is calculated by dividing the height of the window by the individual ItemHeight.

Example:

Display("The inventory window can show %d items at a time", invMain.ItemsPerRow * invMain.RowCount);

displays how many items can be visible in the invMain window at once.

See Also: InvWindow.ItemHeight, InvWindow.ItemsPerRow

The height of my item thumbnails was 21, the height of the GUIControl Object 41.   41 / 31 < 2 so, only one Row was filled.

A good example to make simple things extremely complicated, but at least I know the trick now ;-)
#2
I am using AGS 3.5.0 and the Tumbleweed template and are struggeling with a problem related to the invetory slots.
The template has a 4x2 Grid for items.

As long as I am not adding more than 4 inventory items to the inventory, everything is fine. The items are lined up
in the first row, starting from the left to the right.
However when I add the 5th item with player.AddInventory, the 5th item is not added to the second empty row as expected.
Instead its added to the third row which is only accessable by scrolling.

So in the end, I have:   Row 1: 4 items, Row 2: 0 items, Row 3: 1 item.

Any idea what's wrong or where I can changed that behaviour so that the item is added correctly to the empty row 2 instead of row 3?

Thank you for your help!
#3
I have an odd, but very frustrating issue during development with AGS, and wonder if this could be solved:

I have several save games. Howevr, each time I add a new view to the game (which is not even used), all
saved games made prior to tat change cannot be loaded anymore.

It only gives me an error "#Error: Unable to restore saved game": Missmatching number of views."

Is there a way to keep those saved game states working during development when new views are added?
Or do I have to start all over againg from the beginning each time I want to test a certain scene of my game?
#4
Quote from: Slasher on Sun 01/03/2020 19:45:44
Examples in Rooms Rep Execute

Code: ags

if (Hotspot.GetAtScreenXY(mouse.x, mouse.y) == hotspot[1]) {
 cEgo.Say("Captain. We are bordering on an unauthorised area.");
}
else if (Hotspot.GetAtScreenXY(mouse.x, mouse.y) == hotspot[2]) {
  //Change cursor graphic for Hotspot 2
}

//Etc for other hotspots

//the same applies for Object.GetAtScreenXY(mouse.x, mouse.y) and Character.getAtScreenXY(mouse.x, mouse.y).



Hope this helps...


Not really, this is a routine to check if a certain hotspot is located at given coordinates of the courser. It returns a bolean.

I actually need a method that is returning x & y coordinates of a given hotspot to hand them over to FaceLocation to make the player facing the hotspod, and not facing the cursor position.
#5
Quote from: Cassiebsg on Sun 01/03/2020 19:28:15
When you use mouse.x and mouse.y is not very good solution, cause if you move the mouse they'll change.
So either you save them, by using int MouseY=mouse.y; and int MouseX=mouse.x; right at the start of the function and then use MouseY and MouseX, or the better solution is to just tell it to FaceDirection=Left since you know which direction he will have to use .  ;)

That's a possible workaround I also had in my mind. However as a programmer, I struggle to believe that there is no possibility to get the hotspots location and use that information for FaceLocation.
Without that, the whole FaceLocation functions looks kinda useless to me. At least in combination with hotspots (objects do provide x, y coordinates).
#6
I am heavyly struggeling with FaceLocation in AGS 3.5. Maybe I'm doing something wrong?

This is my setup (using the Timbleweed config):

1. I have a hotspot in a room (basically a plant in the background). The user is able to interact with it via following code

Code: ags

function plant_AnyClick()
{
  player.FaceLocation(mouse.x, mouse.y, eBlock);
  if (Verbs.UsedAction(eGA_LookAt)) {
    player.Say("A little plant I bought at the gas station.");
  }
  else Verbs.Unhandled();


2. I also defined a WalkToPoint right of the plant hotspot

3. In the General Settings I set all options under "CHARACTER MOVEMENT" to true.

4. Walking-Animations for left, right etc. are all set correctly for the player. Same for the talking animations.

This is what I would expect:

1. I trigger "Look at" while clicking on the plant. 
2. The player moves to the WalkToPoint that is defined on the plant (hotspot)
3. Since the WalkToPoint is located right from the hotspot, I would expect the player
    to always look to the left once he arrives at the WalkToPoint.

This is what happens:

Sometimes it works correctly, but sometimes the player looks in the wrong direction when
he arrives at the WalkToPoint and starts talking. It seems like something randomly affects the calculation
what is left and what is right of the player. It also seems that the closer the WalkToPoint is located near the hotspot itself
the more often the wrong direction is chosed.


My theories:

1. mouse.x, mouse.y might change to something else while walking to the walktopoint is still in progress and causing the facelocation method to use the wrong coordinates
    (the mouse is NOT locked while walking, so I guess the coordinates can be overwritten here?

2. maybe something wrong with the timing? Since I can't define a eBlock for WalkToPoint, the facelocation might be triggered to early?


What puzzles me most is, that according to the API, there is no way to get a hotspots x, y coordinates. I guess player.FaceLocation(myhotspot.x, myhotspot.y, eBlock); would solve my problems within seconds.

Anyone else got an idea?
#8
Hi there guys,
After another year of hard work, Space Geekz is finally released:

You can get the game at https://x86-games.itch.io/space-geekz/

A Steam Release will follow the next days aswell.

#9
Thank you guys!

So we have 10 days left, time for me to think about the next stretch goal. If you got any suggestions
plese let me know :-D
#10
UPDATE 15.08.2016

:-D 106% !!! The project reached it's funding goal 36 days before end of campaign. I decided to go add a first strechtgoal: The walkthrough of the premium & international pledges
will be upgraded to a digital story-book. If you got another ideas for possible stretchgoals, please let me know. I am open for ideas! :-D
And of course, you can still back the project if you want to.
#11
NEWS UPDATE 05.08.2016:

We are half way through with Kickstarter. I wanna thank all supporters from Adventure-Game-Studio for their support and of course
I hope other might join in to get us to the funding goal.
https://www.kickstarter.com/projects/2145295147/space-geekz-die-knusperflockenverschworung

This week we took another step:
Space Geekz has launched on Steam this week. If you like this game, and have a steam account, please support Space Geekz!

http://steamcommunity.com/sharedfiles/filedetails/?id=735857311

Honki the Honkifant says Thank you!

#12
thank you guys.

Yes I wanted to do something that resembles the good old times in the 90s. Where black humor in Games
was fine, because no one cared to fit into a certain target group those days. Developers just did "their thing"
and that's what I do here aswell. However, that doesn't work without a single penny nowadays of course.
So that little Kickstarter campaign will help alot getting the game done in the way it should. ;)
#13


Hi there folks,

My new Point & Click Adventure Game “Space Geekz - The Crunchy Flakes Conspiracy (Die Knusperflockenverschwörung)” is on Kickstarter now.

    https://www.kickstarter.com/projects/2145295147/space-geekz-die-knusperflockenverschworung

Yes, an Adventure form Germany NOT made by Daedalic :-D Sorry Edna

UPDATE: The Kickstarter Project is now open for international backers too!
The Game will be available in English & German language.


So what's this Game all about?

Till and Adrian are in their mid 20s and working at the Space Geekz Corporation, delivering game consoles and arcade machines throughout the whole galaxy in their old rotten space freighter.

But one day, in the endless space of the galaxy, something went terrebly wrong: Adrian wakes up with a big bump on his head. Till is gone and the freighter is grounded on an abandoned planet. But what looks like a normal work accident at first, becomes a conspiracy: This is the story about stock trading cannibals, radiactive crunchy flakes, tasteless videogame homage and lots of point & click action from the good old 90s. Of course in pixelated Fake-VGA with amazing 256 colors!
SMF spam blocked by CleanTalk