- rename define DISABLE_SDL --> WITH_SDL (which was already used in some places)
- blenders interation preset was using orbit rather then turntable 3d view preference (different from factory defaults).
- tagged some unused rna args.
- CValue warning ShowDeprecationWarning("val = ob.attr", "val = ob['attr']"); had false positives because of python using getattr() internally. Only show the wanring now when a CValue is found.
- Py functions that accepted a vector and a GameObject were slowed down by PySequence_Check() first called on the GameObject, though this would fail it would try and get attributes from the game object - ending up in ~8 attribute lookups each time. Avoiding PySequence_Check() makes ob.getDistanceTo(otherOb) over twice as fast.
- Joystick hat events could crash the BGE for joysticks with more then 4 hats.
- PLY Import failed on PLY files from Carve, added some extra types.
if(SDL_PollEvent(&sdl_event)) // if -> while fixed it
removed 'm_buttonnum' was misleading, wasn't used as you expect.
Added gravity to variable to world to be used by collada.
bug reported by blenderage on blenderartist (found other bugs too).
- "All Hat Events" didnt work.
- Multiple hats didnt work
- use a menu with direction names rather then have the user guess. disallow zero as a direction.
- Allow up to 4 hats (was 2).
- Python api was clamping the axis to 2, maximum is currently JOYAXIS_MAX - 16
- New python attributes hatValues and hatSingle, match axis functions.
- Use SDL Axis events to fill in the axis and hat array rather then filling in every axis with SDL_JoystickGetAxis for each axis event.
- Raised limit of 2 axis to 4 axis pairs (4==8 joysticks axis pairs)
- Added a new Joystick Sensor type "Single Axis", so you can detect horizontal or vertical movement, rather then just Up/Down/Left/Right
- added Python attribute "axisSingle" so you can get the value from the selected axis (rather then getting it out of the axis list)
- renamed Py attribute "axisPosition" to "axisValues" (was never in a release)
If we need to increase the axis limit again just change JOYAXIS_MAX and the button limits.
kept as the original file, but that can't work correct for solving
relative paths once a .blend in another directory is loaded. The
reason it went OK with the apricot tech demo is that the images there
were lib linked into the level file, which still worked.
Now it sets G.sce to the current loaded .blend file. Note that the
python config file path still uses the first loaded .blend file so it
looks in the same location each time.
Also added some NULL pointer checks in the joystick code because it
was crashing there on Mac, there's similar checks in related functions
so I'm assuming this was just a missed case.
* use SDL events to trigger the sensor, trigger was being forced every tick. removed workaround for this problem.
* added "All Events" option, similar to all keys in the keyboard sensor.
This means every event from the joystick will trigger the sensor, however only events from the selected type (axis/button/hat) is used to set the positive state of the sensor.
* Added python function sens_joy.GetButtonValues(), returns a list of pressed button indicies.
* Removed pressed/released option for joystick buttons, it was the same as the invert option.
The event queue was running for every joystick sensor without checking if the events were for that joystick.
seperating the event queue for each joystick is overkill so instead deal with all joysticks events in once function.
Also removed some unused functions