Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / AgkSharp for Windows - General Questions And Feedback

Author
Message
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 17th Dec 2019 13:57
Sorry, I can't reproduce the error. When I use the standard project everything works with the escape key as it should.
Do you notice the same behavior when you compile and execute the default template as it is?
Do you query the escape key to trigger certain events yourself?
Which AGKSharp version do you use?
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 18th Dec 2019 09:39
Hi MadBit,
It's definitely something to do with scaling as my machine is on 125% scaling and if I go to 100% the problem goes away.
I am not using the escapekey in any way and have removed any possible reference to it.
If I remark out these two lines from Core.cs it happens in the template:

Can you try on 125% and see what happens?
Using AppGameKit V2 Tier 1
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 18th Dec 2019 20:16
You're right. You're right. If I try it under windows 10 with 125% zoom, the window will scale down. That with every key you press.

I've been able to track the issue down to a function in Core.PassKeyDown.
If I comment out all lines that call the function System.Windows.Input.Keyboard.IsKeyDown. The problem does not occur any more.
The strange thing is that this function does not even have to be executed. It is enough if the function is present, and the window already scaled down again.
The same applies to the KeyUp function.
But I don't know how to fix it, because it is a system function. The function is also important to differentiate between right and left shift-/ctrl and alt key.

Any suggestions?
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 18th Dec 2019 20:40 Edited at: 18th Dec 2019 21:05
I wonder if it has something to do with when you initialize/install the keyboard handler (Before you set the window size)

Is it this?

or possibly use the AppGameKit methods to read the keyboard
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 19th Dec 2019 07:20 Edited at: 19th Dec 2019 07:22
@blink0k
That's exactly the problem. Thank you. It looks like it's a known problem.
Unfortunately I did not find a fix for it.

The AppGamekit function to query the keyboard needs this C# function to work at all. In Core.cs all keyboard and mouse inputs are passed to AppGameKit. So that the queries about e.g. GetRawKeyState work at all.

@baxslash
I have now fixed this bug by importing another c++ function. And work with it. In the next update the templates will be corrected. For the moment, you can also change the code snippets yourself.

In Core.cs on top of the other PInvokes


And change the Methods PassKeyDown and PassKeyUp


I hope it helps and there are no unexpected problems with that.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 22nd Dec 2019 08:05 Edited at: 22nd Dec 2019 08:07
Okay, and here's the last update for this year.

LOG:
Equal to AppGameKit Classic Version 2019.12.16
Some features are not available under AppGameKit Cassic and AgkSharp and are only available in the Studio version.

FIX - On windows computers, pressing a key caused the window to be rescaled when the surface was enlarged.

Download site




I wish you all a merry christmas and a happy new year.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 8th Jan 2020 09:41 Edited at: 8th Jan 2020 09:46
Thanks MadBit, I haven't logged in here for a while so just seen this. I think I will test the update with my project and see if it fixes it. I went to 100% scaling temporarily and may stick to it now if it doesn't strain my eyes too much. My project is coming along nicely and I will be sharing a WIP thread soon for some feedback.

EDIT: I made those changes in the Core.cs file and it is now working fine thank you!
Using AppGameKit V2 Tier 1
OriginalKronos
7
Years of Service
User Offline
Joined: 10th Nov 2017
Location:
Posted: 11th Feb 2020 20:35
Hi, I think there may be a memory leak problem with the following commands:

Agk.GetMeshMemblockVertexRed
Agk.GetMeshMemblockVertexGreen
Agk.GetMeshMemblockVertexBlue
Agk.GetMeshMemblockVertexAlpha

I am using these to query a mesh memblock and write out the colours to a text file. However every time I run the save, the memory usage increases substantially. After going through and eliminating all the other commands I found the above were the issue.
I have worked around this by querying the memblock with Agk.GetMemblockByte instead but I figured I would let you know.
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 12th Feb 2020 17:00
Thank you for pointing that out.
I looked at the lines in the code. In my AgkSharp code, the function is looped through like any other.
In the AppGameKit T2 code I could not find anything about how this memory leak could occur.
Can you give me a small example where and how you retrieve the values? So I can understand it.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
OriginalKronos
7
Years of Service
User Offline
Joined: 10th Nov 2017
Location:
Posted: 16th Feb 2020 13:10 Edited at: 16th Feb 2020 15:31
Here is a simple example. On my machine I see memory usage steadily increasing over time.

Deleted first example in favour of this one. This may be a problem with AppGameKit itself as I see a similar memory usage increase when I run the equivalent code in appgamekit directly.

MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 23rd Feb 2020 10:02
I tested your code snippet.
Can't confirm that bug.
After two hours at a frame rate of about 3000 fps the memory consumption did not increase.
I have no idea why you have a memory leak.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 27th Apr 2020 22:38
I know this is not really part of AGK... but...

Is there anyway for you to add in a different, better kind of editbox?

This being only for windows, the current editbox box is just so bad...

Maybe extra function for AGK-Sharp.
Perhaps it's build in form?
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 30th Apr 2020 11:53
if you have started an Agk-Sharp Forms project then you can use the editbox of Forms
I don't know if this is what you need. Agk-Sharp runs on a separate panel. Creating an editbox next to the panel will not be a problem, but in the panel and adding it to your Agk graphic design will be difficult.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 5th May 2020 15:31 Edited at: 5th May 2020 15:39
I mean a good editbox box like those in unity and epic...
there is no copy, no mouse/pointer select, no paste.
Some of those could be custom programmed, but it just s*ck out of the box.

Also, I do not know if this is a bug, but after copying over the new DLL, the following function no longer work when wider than the current screen.
Such as setviewport from 0,0 than the current virtualresolution.
Such as 19550,108550 instead of 0,0;

Agk.GetSpriteHitTest(bID, Agk.ScreenToWorldX(Agk.GetPointerX()), Agk.ScreenToWorldY(Agk.GetPointerY()));

Everything end up breaking...
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 6th May 2020 05:02
What exactly do you mean by setviewport such a command does not exist.
I have done some short tests with SetViewOffset which works fine so far.

Do you have a code snippet for me?
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 7th May 2020 21:54
I mean Agk.GetSpriteHitTest no longer work after using SetViewOffset() after copying the new dll, nothing was change in code...

I just came from unity that time...
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 7th May 2020 22:07
Did you copy AgkSharp.dll and Wrapper.dll?
Did you also recompile the project again?
Which version was the old one? And to which version did you update.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Qugurun
Valued Member
9
Years of Service
User Offline
Joined: 8th Dec 2014
Playing: AppGameKit
Posted: 7th May 2020 22:46 Edited at: 7th May 2020 23:36
Chmava
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 8th May 2020 02:37
a few post up, that is exactly what I did Qugurun...
bID is the sprite id itself, no code was change, only the dll version.

Yes I copy both dll.

I am not sure which version, but the dll was complied on 24 feb 2019.
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 8th May 2020 06:08 Edited at: 8th May 2020 06:11
@all: New version to match AppGameKit 2020.04.30 is available.

Download here





@Chmava:
I've tested it now. I have taken a project template from Feb 24, 2019 and compiled it with this code.



It's working!
Now I have copied both dll's from version Dec 22, 2019 over the old ones.
Also works!
Project recompiled and started - works too.

I don't know why you have these problems.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 9th May 2020 11:42 Edited at: 9th May 2020 15:23
This is why I mention I am not sure if it is a bug, anyway, could you try the following code?


If that is not it, then perhaps I just need the full of the new complied...
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 10th May 2020 05:16
I tested it the same way.

No difference. It's working!
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 11th May 2020 08:48 Edited at: 11th May 2020 10:01
is there any changes from that old dll to this new one?

Like major changes...?
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 12th May 2020 10:54
These are the changes since Feb. 24, 2019. These are the changes that were made specifically for AgkSharp.
Furthermore, each update will only update to the current AppGameKit - Classic version.


Quote: "FIX - Keycodes of Numpad (Mul, Div, Min, Add, Dec) corected
ADD - AgkNode class.
ADD - AgkShader class.
ADD - AgkMesh class.
ADD - AgkObject3D class.
ADD - Math.Wrap(min, max, val) Function.
ADD - Constructor AgkImage(File, ScaleX, ScaleY) to load a rescaled image. (mentioned by Kyle873)
ADD - Agk.SetSpriteShape(SpriteID, ESpritePhysicsShape) to set the Sprite shape. (mentioned by Kyle873)
ADD - Agk.SpriteSetShape(ESpritePhysicsShape, ShapeID) to set the sprite shape via Sprite class. (mentioned by Kyle873)
ADD - Agk.PlayMusicOGG(MusicID, bool) overloaded. (mentioned by Kyle873)
ADD - Agk.SetDefaultMinFilter(EMinMagFilter) / Agk.SetDefaultMagFilter(EMinMagFilter) overloaded. (mentioned by Kyle873)
ADD - Agk.IsSpriteInScreen(SpriteID) created to check is a sprite in screen. (mentioned by Kyle873)
ADD - SetSpriteShape(SpriteID, ESpritePhysicsShape, ShapeID) to create physics shapes on Sprites. (mentioned by Kyle873)
ADD - AgkFont Class. To load fonts. (mentioned by Kyle873)
ADD - SetFont(AgkFont) for AgkText to set custom font. (mentioned by Kyle873)

FIX - AgkSprite.SetColor can't set other alpha value.
ADD - Math.SmoothStep(t0, t1, t)
ADD - Math.SmoothStepInv(t0, t1, t) the inverse of Math.SmoothStep
ADD - AgkText.GetWidth(start, length) get the pixel width between start and start+length chars.
ADD - AgkText.String property.
"
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 13th Jan 2021 07:11 Edited at: 13th Jan 2021 07:12
As attached, the bug when window is larger then virtual resolution on either height or width.

Attachments

Login to view attachments
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 13th Jan 2021 08:02
As I said, with some code it would be easier to understand.

This test code works so far.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 13th Jan 2021 12:56 Edited at: 13th Jan 2021 12:57
Actually I mean something like this...

Core.CreateWindow(main.WIN_TITLE, 320, 420, false);
if (!Core.InitAGK())
{
return;
}

Agk.SetVirtualResolution(320, 480);

Agk.CreteText(1, "aaa")
Agk.SetTetSize(1, 50);
Agk.settextPosition(1, 320, 200);
Agk.settextalightnment(1, 0);

when it launch, use your mouse to click and drag the window wider...
AKA, resize the window...

If needed, I'll make a video...
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 13th Jan 2021 15:05
So I have now tried it with this code.

And it is as it should be.

You had set the virtual resolution to 320 width and the position also to 320, so understandably no text is visible.
But I think that was a typo.

This is the result


If it's different from yours, then you're welcome to make a video.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 13th Jan 2021 15:37 Edited at: 13th Jan 2021 15:38
I have attach the video file...
It is also with edit box on the latest build you have...

I think the text object has to be off screen to begin with.

Attachments

Login to view attachments
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 13th Jan 2021 16:04
I'm really sorry, but I couldn't see anything on the video.
I only see you pulling an edge. But I can't place any of it in any way.
I don't know which part of the image is Agk and which is not.

Don't you have a screen recorder?

Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 13th Jan 2021 18:12 Edited at: 13th Jan 2021 18:13
I think it is only editbox...

basically if you have a editbox with character it in outside of the view port in which using Agk.SetViewOffset() is program elsewhere to access, it will weirdly show the text element of the editbox when stretch.

The reason this is weird is because if someone has a ultrawide or a super ultra wide, like me, then maxi the window will show those text element out of virtual resolution.
I am not sure if this is an issue in basic....

if the screen width is 320, you need to set the text or editbox at 330 to be out of screen.
Then in window mode, drag it wider until you could see it.
Not sure if this is only affecting my apps...

Basically, the next screen over has over 100 sprite, give or take, and only those text is popping up.
It also have over 5 editbox as well as a whole bunch of text, which is not showing up either, so it is probably only editbox...

Due to legal issue, I am not sure I can even screen shot the whole app...
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 13th Jan 2021 18:57 Edited at: 13th Jan 2021 19:09
Ahh, now I see what you mean.

Unfortunately I have to say - yes it is a bug.
But this bug is also in Agk-Basic.

the following gif shows it in Agk-Basic


This is the test code.


EDIT:
With SetTextScissor(1, 0,0,320,480) you can clip the texts separately.
Unfortunately, this does not work so well with the EditBox.
Otherwise you have to try to hide the elements with your program (SetTextVisible) if they are outside the screen.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 14th Jan 2021 06:31 Edited at: 14th Jan 2021 06:32
Well, I remember this does not happen in godot, but it might also does in unity.
When I did was create 4 giant sprite at the top most 'layer' to cover it all up...
this is why super ultra wide gaming with game build in unity... show some very interesting 'extra' stuff...

Glad to know this does not happen only to me!

I wonder what kind of performance lost if there is over 10 of those screen with over 50 editbox in an app...

And SetTextScissor() might need be to be 're-setup' every time view port is change...
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 6th Feb 2021 14:33
Hi,

Do you know anything about the double tap on a touch screen for a single getpointerpressed() event?
Is this intended?
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 6th Feb 2021 16:50
touch events are not implemented in AgkSharp.
Since I don't own a touch device,I can't help you there and I don't know the behaviour of the touch device.
But maybe you can do it yourself.
Here would be an approach to implement one.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 6th Feb 2021 18:19 Edited at: 6th Feb 2021 18:22
I do have a 'touch mode' that I have created, just wondering why it behave that way...
But that require user to activate it themself...

But I do have what might be a bug!

After launching app in windowed mode, probably full screen mode too...
Also any resolution scaling in windows higher than 100%...
Also to maxi the window...
Click on the app inside the window form to focus the app...
If you hit any key, the app window will scale back as if windows has been set to 100% display scaling!

For example, if you have a 4k screen and 200% display scaling in windows, once you hit any key on the keyboard, it will scale back as if it is 1080p resolution size!

The window size is indeed set to 1080p, but due to windows display scaling, it should appear like it has a window resolution of 4k.
Hit any key on the keyboard and it scale like a 1080p app in a 4k screen! 1/4 the screen...

you could re-maximise and it will fix itself... kind of annoying...

No sure if it is just happening to me?
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 7th Feb 2021 07:04
Could it be that it is this problem that baxslash had already mentioned?
It was solved a few posts later.

So if you are using an older version of Core.cs (timestamp before 19.12.2019) you might want to replace it or edit the suggested changes by hand.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 7th Feb 2021 13:12 Edited at: 7th Feb 2021 13:12
Well... it is still happening with the latest build I got off the site?

AgkSharp-20200507.zip

i am not sure it is the same.

Basically, launch it, focus it, and hit any key...

if not...
Right click desktop, display: scale and layout -> change the size of text, apps and other items

Do you have a 4k monitor?
Windows might automatically set it to 200%.
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 7th Feb 2021 14:14
Just to be sure.
Please show me, from the file Core.cs, the functions PassKeyDown and PassKeyUp (complete).

I cannot detect this behaviour in my case.

And yes, I have a 4k monitor and the scaling is set to 150%. Even when I change the scaling, nothing happens so far.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 7th Feb 2021 16:47 Edited at: 7th Feb 2021 16:50
Well, it may indeed by due to me just copying the dll ovr and not the core.cs, i'll try it after this post...

UPDATE: copying the new core.cs fix it...

It was just an old bug...

Perhaps a proper update guide is needed?
Would love one!

static void PassKeyDown(uint key)
{
switch (key)
{
// Top Row 0-9
case 48:
case 49:
case 50:
case 51:
case 52:
case 53:
case 54:
case 55:
case 56:
case 57:
Agk.KeyDown(key + 215);
break;

// Num pad 0-9
case 96:
case 97:
case 98:
case 99:
case 100:
case 101:
case 102:
case 103:
case 104:
case 105:
Agk.KeyDown(key - 48);
break;

case 16:
if (System.Windows.Input.Keyboard.IsKeyDown(System.Windows.Input.Key.LeftShift))
Agk.KeyDown(257);
else if (System.Windows.Input.Keyboard.IsKeyDown(System.Windows.Input.Key.RightShift))
Agk.KeyDown(258);
break;

case 17:
if (System.Windows.Input.Keyboard.IsKeyDown(System.Windows.Input.Key.LeftCtrl))
Agk.KeyDown(259);
else if (System.Windows.Input.Keyboard.IsKeyDown(System.Windows.Input.Key.RightCtrl))
Agk.KeyDown(260);
break;

case 18:
if (System.Windows.Input.Keyboard.IsKeyDown(System.Windows.Input.Key.LeftAlt))
Agk.KeyDown(261);
else if (System.Windows.Input.Keyboard.IsKeyDown(System.Windows.Input.Key.RightAlt))
Agk.KeyDown(262);
break;
}

if (key > 0 && key < 512)
Agk.KeyDown(key);
}

static void PassKeyUp(uint key)
{
switch (key)
{
// Top Row 0-9
case 48:
case 49:
case 50:
case 51:
case 52:
case 53:
case 54:
case 55:
case 56:
case 57:
Agk.KeyUp(key + 215);
break;

// Num pad 0-9
case 96:
case 97:
case 98:
case 99:
case 100:
case 101:
case 102:
case 103:
case 104:
case 105:
Agk.KeyUp(key - 48);
break;

case 16:
if (System.Windows.Input.Keyboard.IsKeyUp(System.Windows.Input.Key.LeftShift))
Agk.KeyUp(257);
else if (System.Windows.Input.Keyboard.IsKeyUp(System.Windows.Input.Key.RightShift))
Agk.KeyUp(258);
break;

case 17:
if (System.Windows.Input.Keyboard.IsKeyUp(System.Windows.Input.Key.LeftCtrl))
Agk.KeyUp(259);
else if (System.Windows.Input.Keyboard.IsKeyUp(System.Windows.Input.Key.RightCtrl))
Agk.KeyUp(260);
break;

case 18:
if (System.Windows.Input.Keyboard.IsKeyUp(System.Windows.Input.Key.LeftAlt))
Agk.KeyUp(261);
else if (System.Windows.Input.Keyboard.IsKeyUp(System.Windows.Input.Key.RightAlt))
Agk.KeyUp(262);
break;
}

if (key > 0 && key < 512)
Agk.KeyUp(key);
}
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 7th Feb 2021 17:48
This is the old one.
Please use the core.cs from the latest update.
Or change the file as described here.
And try it again.

This has nothing to do with the dll's.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 7th Feb 2021 18:27
I did change it... a few seconds after that post... anyway, thank you!
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 7th Feb 2021 18:40
Sorry, I only saw the code and didn't read what you wrote.
Good if it works now.

Quote: "Perhaps a proper update guide is needed?
Would love one!"

Usually it is sufficient to overwrite the dlls. But with this specific bug, the necessary changes were in this file.
Therefore, the file had to be updated for existing projects.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 12th Feb 2021 05:52
Hi,

I remember why I use the old core.cs...

the app no longer terminate properly...like 8/10 times when the [x] is pressed on the top right...

i have to keep using kllltask /F /PID xxx to terminate the app...

Is there such a bug?
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 12th Feb 2021 21:00
Everything seems to be working for me.
The templates work as they should.
One click on the x and the app is closed.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 12th Feb 2021 21:49 Edited at: 12th Feb 2021 21:50
the app may look closed, but the process still exists...

I waited over 10 minutes and the app with it' pid is still there...

I remember there were so many instance of them in task manager back then...
but now they are invisible some how?

Anyway, I'll test it again on final release...
Maybe it is fix?

Also, will there ever be a AgkWriteLong() & Agk.WriteDouble() function?

Agk basic does not seem to support 64 bit int and float, but c# do?

Would be great if there is!
MadBit
VIP Member
Gold Codemaster
15
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 13th Feb 2021 10:13
As you can see in the gif. Everything is normal.
Share your knowledge. It\'s a way to achieve immortality. (Tenzin Gyatso)
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 13th Feb 2021 16:33
I know it disappeared from task manager, but visual studio is still claiming the process is opened...
That is what I mean...

I will test it in the coming weeks...
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 13th Feb 2021 17:05
I haven't noticed any issues with the process ending. Seems fine on my end
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
Chmava
11
Years of Service
User Offline
Joined: 20th Jun 2013
Location:
Posted: 14th Feb 2021 07:57 Edited at: 15th Feb 2021 06:30
Unable to copy file "obj\Debug-64\xxx.exe" to "bin\xxx.exe". The process cannot access the file 'bin\xxx.exe' because it is being used by another process. xxx
Could not copy "obj\Debug-64\xxx.exe" to "bin\xxx.exe". Exceeded retry count of 10. Failed. The file is locked by: "xxx.exe (14060)" xxx

This happen by hitting the X on the top right...
It has been over 30 minutes...

The build in red square button terminate the process forcefully, so it work fine...

I end up using the old core.cs because it prevent it from happening 99/100 of the times?
It might still happen with the old core.cs...

If there is a bug, it still happen back then...


You can't even find it in task manager, but even for any .exe file, as long as it is opened, you can't even copy and override them..


I also have the following code after the core.loopAGK() while loop


Environment.Exit(1);
System.Windows.Forms.Application.Exit();

Sometime it end properly, sometime it just hang there until force terminate


EDIT: you might have to keep the app open for maybe 30 minutes to serveral hours before this issue will happen...
If you open the app and close it within a few minutes, it tend not to have this issue!

Did it open a file somewhere and did not close it on exit?

It could be one of the thread not terminating...

opening the .exe again, will just open another app, it is impossible to tell unless you try copying another .exe to override it... or delete it...


Update: due to a lack of reply... I assume you have found something?

Login to post a reply

Server time is: 2024-11-21 12:39:02
Your offset time is: 2024-11-21 12:39:02