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

#1
I have my resolution set to 1920 x 1080, confirmed in the settings and everything was looking good until a black bar started showing up on the bottom of the screen. Did some troubleshooting thinking a transparent GUI was oversized and forcing a more dramatic horizontal aspect ratio. Didn't find anything there. Then when I went to create a walkable area, the bottom edge would only go to 1020 before becoming a question mark off of the stage. Double checked to make sure I didn't turn 1080 to 1020.

Worst case scenario, I have a black bar at the bottom of the screen, which I can deal with. But having a 1020 Y axis made me think it might be something I'm overlooking. Thanks for any help.
#2
I have had this issue on 3 different computers, which leads me to believe that my file is corrupted, which is a mild crisis since I've been working on this on and off since 2006.

I just installed the newest patch of AGS on a new computer. My AGS files are on a flash drive. I can't currently find any other folders it's accessing. Thought I might have the game open or something, but just 1 ags file.

#3
Error: Unable to delete the file 'D:\acres\_Debug\acres.exe'.
Access to the path 'D:\acres\_Debug\acres.exe' is denied.
Version: AGS 3.6.1.25

AGS.Types.CannotDeleteFileException: Unable to delete the file 'D:\acres\_Debug\acres.exe'.
Access to the path 'D:\acres\_Debug\acres.exe' is denied. ---> System.UnauthorizedAccessException: Access to the path 'D:\acres\_Debug\acres.exe' is denied.
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.File.SetAttributes(String path, FileAttributes fileAttributes)
   at AGS.Editor.Utilities.TryDeleteFile(String fileName)
   --- End of inner exception stack trace ---
   at AGS.Editor.Utilities.TryDeleteFile(String fileName)
   at AGS.Editor.BuildTargetDebug.DeleteMainGameData(String name)
   at AGS.Editor.AGSEditor.CreateMiniEXEForDebugging(CompileMessages errors)
   at AGS.Editor.AGSEditor.CompileGame(Boolean forceRebuild, Boolean createMiniExeForDebug)
   at AGS.Editor.Components.BuildCommandsComponent.TestGame(Boolean withDebugger)
   at AGS.Editor.Components.BuildCommandsComponent.CommandClick(String controlID)
   at AGS.Editor.GUIController._mainForm_OnMenuClick(String menuItemID)
   at AGS.Editor.MainMenuManager.MenuEventHandler(Object sender, EventArgs e)
   at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
   at System.Windows.Forms.ToolStripMenuItem.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.ToolStripDropDown.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 System.Windows.Forms.ToolStripDropDown.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)
#4
Yes, the room editor. I have created a side scroller where the entire background is an object in a room where there is no baseline override set (I will double check and report back)but my character walks towards the background up on the Y then suddenly disappears behind it when walking north on the Y axis. I don't have any walk behinds in the room. My instinct tells me it's a baseline issue because of the behavior, but I can't identify why my character would appear in front of the background, and even overlap it then suddenly disappear
#5
Feels like it should be simple but I've checked all the baselines and walkable areas are suddenly disappearing behind objects even in new rooms. My characters disappear behind the objects on these walkable areas as well. Neither characters, objects nor walkable areas have a z layer so i'm just wondering if i've overlooked some setting I was unaware of.
#6
I have a Journal section of my game in which rectangular images show things you've learned.

I'm trying to stack these images on top of each other so they descend from most recent information to least recent. So each time you "unlock" a piece of information, it will show up at the top of the stack.

My instinct was a list box, but I couldn't figure out how to replace text with images. So then I tried to use multiple GUIS that all contained the journal options in buttons stacked on top of each other, but that made it difficult to scroll without setting a thousand variables.

Then I tried a second inventory box, but I couldn't figure out how to call out to the images without adding inventory to my actual inventory.

Is there a simple method to stack images in descending order with the capability of scrolling? Thanks
#7
that did it. Appreciate you!

....on an unrelated note, 76,000 views for this thread is odd lol
#8
Quote from: Crimson Wizard on Thu 08/02/2024 17:24:30
Quote from: Brian925 on Thu 08/02/2024 17:14:21when I switched to ...

No, this is not supposed to happen.
Could you post a screenshot illustrating this problem?


This is mid fade. The outline of the entire image suddenly shows up then disappears, ignoring transparency

https://imgur.com/a/FwGqhiB
#9
Quote from: Khris on Wed 07/02/2024 18:02:21I also doubt you need 20 GUIs for this; to show a graphic (or text) on screen you have various other methods available (like GUI buttons, or graphic overlays).

Just a follow up to this: when I switched to GUI buttons, the images I'm using are now showing a subtle rectangular outline of the entire image when they fade to 100% transparency. Is that just to be expected with GUI buttons?
#10
Buttons totally slipped my mind, thank you. That should do the trick
#11
I know the chances are slim, but I figured I'd check with the experts.

I have two announcement GUIs with generally the same look. I tried to be slick and create this function in the Global Script:
Code: ags
  function ingredient_announce() //an attempt to limit timers. //sends to 72 global 
  { 
  gAvoAnn.Visible=false; //resets first announcement
  gJalAnn.Visible=false; //resets second annoucement
  SetTimer(1, 180); //starts a timer
  
  if (avocado == 1){      //makes option 1 or 2 visible
    gAvoAnn.Visible=true;
    gAvoAnn.Transparency=0;
  }
    
   else if (jalapeno == 1){
   gJalAnn.Visible=true;
    gJalAnn.Transparency=0;
   }
     

Then when the timer expires, it calls to this in repeatedly execute in the global script:
Code: ags
   if(IsTimerExpired(1)){ //both avo and jala timers are expired if they have respectively been called.
    jalatimerdone=1;
    avotimerdone=1;

if (jalapeno == 1){
gJalAnn.TweenTransparency(0.2, 100, eNoBlockTween);}
  else if (avocado == 1){
  gAvoAnn.TweenTransparency(0.2, 100, eNoBlockTween);
  }}

In the room, the object you click on sets off the necessary variables and function with this code:
Code: ags
   avocado=1; //tells that avocado is in play, jalapeno would be jalapeno=1. 
    ingredient_announce()

As expected, whatever I clicked first handled properly, but the next announcement would not fade although the proper announcement would pop up. I imagine this is because the timer has already been executed, so I was hoping there was a way to reset the timer each time an announcement is made.

To sum up:
1. Is it possible to reset the timer so it handles more than 1 image fade?
2. I have several announcements fading in this fashion...way more than 20. Am I out of luck in having more than 20 GUIs that fade out because each one requires a unique timer?





#12
I'll definitely explore that and check back in. There's a lot of character views to dig through, I'll check on all the locking and see where the error might be.
#13
It's only when the character is facing left or right, not up or down.
What part of the code handles the IdleView? I didn't see anything in the global script that could have specifically ruined the left and right IdleView but not the Up and Down.
#14
Quote from: RootBound on Sun 04/02/2024 14:35:39
Quote from: Brian925 on Sun 04/02/2024 14:14:08I've recently imported a Tween module that I'll dig through to see if it's conflicting with any of my code.

The tween module from these forums shouldn't interfere with anything unless you're writing your own tween code elsewhere and using the same names for things (which still shouldn't affect character views at all). It's self contained. It just adds extra commands and functionality that you can call when you want it.

Okay, that makes sense.
I have the old KeyboardMovement module installed too that I recently set to Pressing instead of Tapping, and then upgraded from 3.4 to 3.6 AGS. It told me it needed to update the code and it wouldn't be backward compatible. Could that be it?
#15
All good insight. I've recently imported a Tween module that I'll dig through to see if it's conflicting with any of my code. I also started making my game in an earlier version of AGS, and it had to rewrite the code to make it work with 3.6. I'll keep exploring.
#16
I have a character who moves in four directions, but when IdleView kicks in, it forces him to face forward.

I do this by creating a Walking View with 4 loops that each represent one of the four cardinal directions. (Loops 0(Down),1(Left),2(Right),3(Up). No IdleView set.

I have an additional, separate View for IdleView (instead of just setting the sprite in the character) that has only 2 frames of the same character closing his eyes, facing forward on Loop 0.I did it like this because setting the BlinkView did nothing when I assigned a sprite to it, so I used IdleView to achieve the same effect.

I did NOT place IdleView sprites in the Left, Right or Up loops, and that has forced it to default back to the front facing walk cycle loop.

That worked until it didn't. I'm suddenly getting the error message: AnimateCharacter: invalid starting frame number specified.

Is there a simpler way? Could something in my code prevent BlinkView from working?

Thanks for any help.




#17
Quick question on this one. Felt like this module was the play for no block tweening but it's not fading before disappearing. Any ideas?

Code: ags
if(IsTimerExpired(3)){
gFirstIngredient.Visible=true;
gFirstIngredient.TweenTransparency(0.5, -gFirstIngredient.Transparency, eEaseOutBackTween);

Module installed in scripts.
Just trying to get to show up, hold for a second and gradually fade into the background without stopping the character movement. Thanks!
#18
I think what you mean is you don't know how to erase it?

Basically, you have to go to the room you have the walkable area, click "show this rooms" and scroll it to "walkable areas". You'll notice in the properties, all of the walkable areas have a property 1, 2, 3, 4 etc. If you click that drop down menu and set it to "walkable ID area 0" that will put you in eraser mode. then you just drag the square like you are creating a walkable area....but instead of creating it, it will erase what currently exists in that space.

I thought this was an important topic, so I chose to bump it since I had the same problem in the past.

#19
I'm trying to fade in a GUI and I'm not sure if how it's embedded is getting in the way. I was also curious if having the GUI set to "pause game when shown" would cause the fade not to happen. I got the code to work for everything except the fading part until I started messing with the brackets and getting errors. Thanks for looking.

Code: ags
function btnInvOK_Click(GUIControl *control, MouseButton button) {
	// They pressed the OK button, close the GUI. Everything should always be set to invisible.
	gInventory.Visible = false; //Makes overlay Inventory GUI close
  gIconbar.Visible=true; //restores visibility of Top Bar GUI
  gIconbar.Clickable=true; //restores functionality of Top Bar GUI
  
  if(onmega == 1) {
  gGB1.Visible=false;
  else //GETTING A PARSE ERROR HERE AT 'ELSE'
  gGB1.Visible=false;}
    
  if(podtoinventory == 1){
  gGIOPod1.Visible=false;
  else
  gGIOPod1.Visible=false;}
  
  if (blend1done == 1){
  gAnn1000.Visible=false;}
  else
  if(blendglovematch==1){
  Wait(20);
  gAnn1000.Visible=true;}
  int trans2 = gAnn1000.Transparency;
  while (trans2 > 0){
  trans2--;
  gAnn1000.Transparency = trans2;}
  Wait(1);
  
  else 
  gAnn1000.Visible=false;
  gArena.Visible=false;
  mouse.Mode=eModeInteract;
 }
#20
Thanks guys,

Snarky, I originally thought the most effective way to return the images was in a GUI button from Khris' original explanation that returned a string. I see now that it adds steps where it doesn't belong for returning images instead of text.

I agree about the wrong mental model. As a self taught coder, I have a lot of blind spots. In the past, I could survive with a bunch of if/than statements, but this time around, I'm trying to really understand putting arrays together and consolidating my code. When I'm given example code, I'm not always sure what I should replace with my content, which parts are returning previous code and which parts are calling premade functions I'm not aware of. Just need more hours.

Khris, that one worked perfect. Kind of a cool concept to label the sprite number at a recognizable interval to save some coding time. Thanks so much for both of your help.



SMF spam blocked by CleanTalk