Annoying bug?

The Partridge Family were neither partridges nor a family. Discuss.
User avatar
LuX
Posts: 1492
Joined: April 22nd, 2012, 12:33 pm
Location: Finland

Annoying bug?

Post by LuX » April 30th, 2012, 8:05 pm

So I was coding and messing around in c++... When all the sudden... I notice intellisense stops correcting me! Well, I thought I had made some mistake somewhere, so I build the solution:

1>------ Build started: Project: Chili DirectX Framework, Configuration: Debug Win32 ------
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========

Hmm... I thought, I used to get miles long warning lists, but now I get nothing.
So I typed in something random, like "Chili is awesome", we all know that should come up as error, right? Nothing. Tried the same thing on another project. At first it worked normally, but after a while this bug struck again. I tried to reopen multiple times, even rebooted, but I still have this!

I'm getting really frustrated.
ʕ •ᴥ•ʔ

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Annoying bug?

Post by chili » May 1st, 2012, 2:51 pm

You know the rules bro, post your code if you want some help. ;)
Chili

User avatar
LuX
Posts: 1492
Joined: April 22nd, 2012, 12:33 pm
Location: Finland

Re: Annoying bug?

Post by LuX » May 1st, 2012, 5:02 pm

This wasn't really a code based problem to begin with...

But I think I found the problem, but not an actual solution:
When I make a backup of the whole project file, it seems as if the new file and its solution ignores the new folder an just keeps working in the original folder, so any work done in this new folder is ignored and when I debug, it just uses the original debug, sort of having a siamese twin folder which work had in hand, but uses only the original ones data files and debug.

So my solution is not to do backups, but I really wanna have backups, so what gives?
ʕ •ᴥ•ʔ

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Annoying bug?

Post by chili » May 2nd, 2012, 12:35 am

What folder are you backing up exactly, the solution folder or the project folder?
Chili

User avatar
LuX
Posts: 1492
Joined: April 22nd, 2012, 12:33 pm
Location: Finland

Re: Annoying bug?

Post by LuX » May 2nd, 2012, 12:31 pm

After I stop coding, I close all files and exit the program, then I copy paste the whole file with all the stuff in it on the desktop and rename it. Essentially I keep 3 copies of the same project in steps, so that if one has major errors or gets corrupted, I can always go back a step or two.

It seems to help if I paste the file to a different directory. Maybe the renaming screws something up?

Oh, and a second thing: How do I show a form and access it through game.cpp?
Basically I added a windows form to the project and added some labels to it, so it could display some of the calculations I make. It would really help to see what results the program gets as some of them seem to give funky results.

So what are the c++ equivalents to form1.show, form1.hide, form1.label1.text = ""?

AND, as if i'm not already asking a lot at once. How can I set the frameworks borders to none?
ʕ •ᴥ•ʔ

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Annoying bug?

Post by chili » May 3rd, 2012, 5:24 am

To access the forms you make in the Visual Studio form editor you have to be using .NET. You need to use CLI and you need to have some kind of interop between the managed (.NET) stuff and the unmangaged stuff.

I would be easier to create a dialog window with WIN32 calls and use that to display stuff, but you would need to learn some WIN32 to be able to do that. ;)
Chili

User avatar
LuX
Posts: 1492
Joined: April 22nd, 2012, 12:33 pm
Location: Finland

Re: Annoying bug?

Post by LuX » May 3rd, 2012, 1:38 pm

I tried to use a console earlier by adding it with AllocConsole; but I wasn't able to add text to it using cout or any of the other I tried... I've done some simple things with consoles in VB language, like text based games and stuff.
ʕ •ᴥ•ʔ

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Annoying bug?

Post by chili » May 3rd, 2012, 1:55 pm

Do you know how to use stdio? You can try fprintf( stderr,"format string",arg1,arg2,... ) and it will give you output on the debugger console i believe.
Chili

User avatar
LuX
Posts: 1492
Joined: April 22nd, 2012, 12:33 pm
Location: Finland

Re: Annoying bug?

Post by LuX » May 3rd, 2012, 2:33 pm

I have been a bit busy lately, but I remember trying to use OutputDebugString, Haven't had the time to investigate it further.
ʕ •ᴥ•ʔ

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Annoying bug?

Post by chili » May 3rd, 2012, 3:25 pm

I think I've heard of that one too (maybe even used it once). Also very worth looking into.
In a few more lessons we'll be able to render text to the window graphically, so either way the problem will be solved sooner or later. ;)
Chili

Post Reply