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

#281
Quote from: Mandle on Thu 29/08/2019 02:14:46
You could use the dummy character method and just put one on every area.

Personally I would just manually test for the distance from the character to each of the area's coordinates using Pythagoras' formula instead of using dummy characters.

I like your idea! How can I access and address all the coordinates of the Walkable area and let the computer run through all of them one by one? What command or function can I use for that?

And for your elaborate dummy method: when my character stands inbetween two Walkable areas, outside any Walkable area, I want the closest coordinate to a specific Walkable area, not necessarily the Walkable Area closest to the character. I don't understand how multiple dummies would help here?
#282
eri
Quote from: eri0o on Wed 28/08/2019 18:20:35
Place a dummy character in the same position of the character and do cDummy.PlaceOnWalkableArea() and calculate the distance between the two.
Quote from: morganw on Wed 28/08/2019 21:01:53
I think that technically you could note the current co-ordinates of the player, then call PlaceOnWalkableArea, note the player's co-ordinates again, and then place them back in the first position.
(if you wanted to avoid the need for a dummy character)

Thanks eri0o and morganw! I implemented the PlaceOnWalkableArea() function and it works like a charm!!! Thanks a lot!
#283
Quote from: Khris on Thu 29/08/2019 10:29:39
Quote from: TheManInBoots on Wed 28/08/2019 18:12:29It would help if the character for example ends up outside the walkable area due to a random animation or view change

That sounds like you're trying to solve a problem that should never occur in the first place. Animating or changing the view doesn't change the character's position; if you have an animation that's misaligned and you're doing something like  player.x += 5;  beforehand, the solution is to properly center the frames, not mess around with dummy characters and the like.

if the character changes view picking up, carrying a long object it changes sprite dimensions posiiton etc. with shadow and y coordinate chandge, inaccuracies due to scaling . very useful dummies
#284
Quote from: Crimson Wizard on Thu 29/08/2019 03:03:06
Quote from: Mandle on Thu 29/08/2019 02:14:46
Personally I would just manually test for the distance from the character to each of the area's coordinates using Pythagoras' formula instead of using dummy characters.

The point is in knowing these coordinates, which AGS does not provide. You'd have to ask AGS for walkable area ID per each pixel around character while increasing radius until you get the first walkable pixel.
This is roughly what AGS is doing in PlaceOnWalkableArea, and it will do it much faster natively than script.

Right now I just remove the other Walkable Areas around to find the closest point to the wanted Walkable area while using the PlaceOnWalkableArea function.
But that sounds really interesting, how would I script that if I really would basically want to use the PlaceOnWalkableArea manually and script it myself as you said?
Would I have to use C language actually or are AGS commands sufficient?
#285
Is there btw. a way to find out the distance to a SPECIFIC walkable area? That would make it easier, because then I don't have to remove all the nearby walkable areas around the character just to find out the closest coordinate to the walkable area that the character should actually stand on.
#286
I guess it won't be worth it to try re-importing and saving smaller chunks in a non-beta version.
#287
Yes, I noticed that I could re-import smaller amounts of Sprites and then save the game, so I already tried that.
But the bug remains.  :~(

#288
OK cool, the PlaceonWalkableArea function sounds like it's just what I need! Thanks! I'll try it out!
#289
Hi all!

Is there a way to calculate the point of a walkable area that is closest to the character?
It would help if the character for example ends up outside the walkable area due to a random animation or view change, and so that I can correct that and make the character walk back to the walkable area in the most efficient way, especially since the walkable area is shaped in a complex way.
#290
Okay, I tried re-importing from source in the new beta version 3.5.0, saving and all, but the bug remains.

The sprite file or some memory remain corrupt.

#291
Thanks for your input Crimson Wizard.

I was re-importing my frames from source, exactly what you suggested. It was going quite well but at some point I received this error message:

https://drive.google.com/file/d/1VlD_Bnz8kiGYPr33C6C2hvJ8n4y4p_-m/view

I'll look into the beta version.
#292
I have a specific question on this:
How are the rules for copyright strikes?
Can you actually publish a game with Harry potter themes without problems?
#293
I installed the newest version on this site (3.4.3.1).
So, after that:
Setting compress sprite files to true, false and true again and saving the project every time in between (yeah, weird, I know!?) allowed me to add about ten more sprites before the same problem and error message occurred.
Yeah, adding dynamic sprites could help me out a little bit for a few sprites if dynamic sprites are really not saved in the sprite file.
However I would still like to add an elaborate intro animation which will include at least 500 more sprites, and I cannot add all those as dynamic sprites, that would be insane and really impractical.

I experimented a little bit and noticed that if I set "compress sprite files" to true from the very beginning of a project I can add high number of sprites without problems and also without the extreme slowing down of the system when adding and saving sprites.
So my assumption is that  clearly the software has problems changing the sprite file from compressed to not compressed, and also re-saving and re-structuring the sprite file properly, once you added a high enough number of non compressed sprite files.

Is there any way to completely delete the sprite file (and it's sprite backup file and associated files) and then let the software save my project and my sprites from point zero so to speak, everything as compressed files? Because that should remove the bug in my estimation.
#294
Hi everyone!

I cannot make Adventure Game Studio function anymore for a game that I have been working on over the last months.

Each time I add at least one new Sprite and then try to save the project, I get and an error message with this bug report:



Error: Attempted to divide by zero.
Version: AGS 3.4.1.13

System.DivideByZeroException: Attempted to divide by zero. ---> System.DivideByZeroException: Attempted to divide by zero.
   at save_sprites(Boolean )
   at save_game(Boolean compressSprites)
   at AGS.Native.NativeMethods.SaveGame(Game game)
   at AGS.Editor.NativeProxy.SaveGame(Game game)
   at AGS.Editor.AGSEditor.SaveGameFilesProcess(Object parameter)
   at AGS.Editor.BusyDialog.RunHandlerOnThread()
   --- End of inner exception stack trace ---
   at AGS.Editor.BusyDialog.Show(String message, ProcessingHandler handler, Object parameter)
   at AGS.Editor.AGSEditor.SaveGameFiles()
   at AGS.Editor.Components.FileCommandsComponent.CommandClick(String controlID)
   at AGS.Editor.ToolBarManager.ToolbarEventHandler(Object sender, EventArgs e)
   at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
   at System.Windows.Forms.ToolStripButton.OnClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
   at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
   at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
   at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ToolStrip.WndProc(Message& m)
   at AGS.Editor.ToolStripExtended.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)



I tried restarting the program, even restarting my computer, with no results. The problem remains.
Also it took quite a long time to save new files- the sprites- in the project, before the error occured, way longer than it does with new projects I work on.
I have a very high resolution for the game -1600x900- and I use high quality photos as graphics. My sprite file is a little over 2,8 GB big. I have approximately 1500 graphic files, maybe some more, around 1700, I cannot say for sure because the automatic graphic numbering of the software is not entirely regular.
I can still save projects with new Sprites when I open other projects, just with this game I have been working on for so long it does not work.

I have no idea how I could fix this problem, but I would greatly appreciate any helpful advice, I have been working on this game for a long time and I would soon finish it, but now this is holding me back.

TheManInBoots
SMF spam blocked by CleanTalk