Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5934649
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T15:08:35+00:00 2026-05-22T15:08:35+00:00

I have a strange bug that appears to happen only when the program isn’t

  • 0

I have a strange bug that appears to happen only when the program isn’t executed from the terminal. Here is my project:
https://github.com/elliotpotts/Troll/
https://github.com/elliotpotts/Troll/issues/2

Look at the Troll::State::keyPressed() function. For some reason when I run the program from the terminal, everything is fine and the application exist but when I run it as a GUI program, the appliction doesn’t exit. I can’t think why. Thanks in advance, ell.

EDIT: Apologies for not adding Ogre tag and not posting the keyPressed function, here it is:

void Troll::State::keyPressed(const OIS::KeyEvent& event){
    if(event.key == OIS::KC_Q) {
        mCreator->stop();
    };
};

I have also tried adding file output to test it:

void Troll::State::keyPressed(const OIS::KeyEvent& event){
    std::cout << "Q was pressed" << std::endl;
    std::fstream file("log");
    file << "Q was pressed";
    file.close();
    if(event.key == OIS::KC_Q) {
        mCreator->stop();
    };
};

When run from the terminal, this works, otherwise, it does not. An added note, I do not have a functioning debugger at the moment which I am also trying to fix. Ell.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T15:08:36+00:00Added an answer on May 22, 2026 at 3:08 pm

    It turns out it was the IDE causing the problem, thanks for your help anyways, ell 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Here is the pattern: $urlpattern = '%[^http://][^https://][\w]+(-[\w]+)*(\.[\w]+(-[\w]+)*)*\.[\w]{1,6}(\.[\w]{1,6})*[^/]%'; I have encountered a strange bug that
I have a rather strange bug which i can't make sense of that is
I have a very strange bug in a shipping iPad/iPhone app that I can't
I have found what appears to be a strange bug with sqlite. I have
Boy do I have a strange bug. I have a website that needs to
I have an extremely strange bug. I have two applications that communicate over TCP/IP.
I have a strange bug. I launch a PHP Unit test Suite. At the
I have a very strange bug, which I believe is caused by some code
I have a really strange enum bug in Java. for(Answer ans : assessmentResult.getAnswersAsList()) {
I have come across some strange behaviour, and I'm assuming a bug in Firefox,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.