weimingtom / angel-engine

Automatically exported from code.google.com/p/angel-engine
0 stars 0 forks source link

Problems about arrow's keys input #70

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Arrow's keys were not work well.

I checked code and found a little problem at InputManager.cpp:

bool InputManager::OnKeyDown( int keyVal );

this function need a char range check before tolower():

    if (keyVal <= 'Z' && keyVal >= 'A')
        keyVal = tolower(keyVal);

The same problem maybe in IsKeyDown(), but i'm not sure.

BTW: Any method to flip horizontal a actor? It's useful to the game characters.

And I think theCamera is too weak.

I hope theCamera can focus on a actor, and zoom in or zoom out more easily.

Finally, thanks for the engine, I like it very very much.

Original issue reported on code.google.com by fy0748 on 17 Dec 2012 at 5:17

GoogleCodeExporter commented 8 years ago
This is kind of a scattershot report -- lot of separate unrelated issues. 

Not sure what you mean about the arrow keys. Please file a separate bug with 
sample code and expected behavior.

If tolower is passed an invalid value, it simply returns that value unchanged, 
so there's no need for a range check. 

You can adjust the texture coordinates on an actor to get a flip -- check the 
Actor documentation at http://docs.angel2d.com/

If you have some ideas for improving the camera class, please write up some 
more specific notes on what would be useful and send them to the discussion 
list. 

Original comment by lieseg...@gmail.com on 17 Dec 2012 at 7:27

GoogleCodeExporter commented 8 years ago
OK.I'm sorry.

Should I reply the topic ? or make a new issue?

Maybe tolower() and toupper() not work well on a chinese locale set platform.

Original comment by fy0748 on 18 Dec 2012 at 2:25