WHAT IS
3D RAD?
CLICK HERE
TO FIND OUT!


ConfigureControls


Add support for any input device to your 3d projects!

Keyboard, joysticks, gamepads, steering wheels and any other input device that can be installed under Windows� will be available to, and fully configurable by users of your projects.


USAGE

Usage is absolutely straightforward. Just add this object to your 3D Rad project and double-click it in the Object List to open the configuration dialog.



Controls & Descriptions. 3D Rad supports up to 32 configurable controls.

If you want a control to be configurable run-time by users of your project, simply specify a description in the input box next to the control.

This description is shown to the user during run-time configuration.

You can define the order in which the controls are configured by specifying a priority value in the description. For example (see picture above), if you want the Jump control to be configured first and Move Forward/Backward last, then type the descriptions as follows:

Move Forward @4
Move Backward @5
Turn Left @2
Turn Right @3
Jump @1

Priority values must be between @0 and @31. Where no priority is specified, @0 is assumed.

Color, size and screen location of the descriptions are definable to adapt to the custom background image you can use as GUI.

Text color & opacity. Click the color button to open the color picker. Opacity must be between 0.0 (invisible) and 1.0 (fully visible).

Text width & height. Any size is allowed, but values bigger than 2.0 may reduce rendering quality.

Text's screen location. The screen center is at 0,0. Left/right margins are at -16 and 16. Top/bottom margins are at 12 and -12.

For information about the remaining controls, please click here.


RUN-TIME CONFIGURATION


If you have specified a description for at least one of the 32 controls (see above), users of your project can enter the run-time configuration procedure, by pressing [LeftCtrl]+[LeftShift]+[F9].

By default, as GUI, the ConfigureControls object provides simple semi-transparent panels with some text. You can customize these as explained below. The default GUI can be rendered as an overlay, like in the following example:



If the user chooses to assign the control to a proportional device, the panel changes to the following:



The system can automatically detect any connected input device. If the input is successfully detected it is assigned to the current control and the following message appears:



The procedure cycles through all the controls you have made user-configurable.

CUSTOMIZING DEFAULT CONTROLS


Each new 3D Rad project comes with default controls, all assigned to the keyboard.

If you want to re-map these default controls for your project:

  • add the ConfigureControls object to a runnable project


  • open the property dialog for it and type a description for the controls you want to re-map and click OK


  • press the [SpaceBar] to launch the project


  • press [LeftCtrl]+[LeftShift]+[F9] to start the run-time configuration procedure


  • The new settings will become the default for your project. If you don't plan to make them re-configurable by the final user, you can remove the ConfigureControls object from the project.

    WARNING! Setting the defaults to controls on a device other than the keyboard is not recommended. The input controls may not work on systems where the original device is not installed, unless the user re-configures them.

    REMARKS


    In a multi-level compiled project, the ConfigureControls object should only be present in one single level (for example the entry-point project, or a game menu), if you want the settings to be preserved from one level to another.

    CUSTOMIZING THE GRAPHICAL USER INTERFACE


    To modify the static background included to the ConfigureControl object, you must replace, in the

    .\3DRad_res\objects\ConfigureControls\data\

    folder, the files called

    controlA.dds
    controlB.dds
    controlC.dds

    with your own picture files in one of the following formats: .dds, .png, .tga, .jpg, .bmp.

    While the file extension can change, the file names must be controlA, controlB and controlC. For example, valid file names are controlA.jpg, controlB.jpg and controlC.jpg.

    The 3 files are the first, second and third message shown in the pictures above, respectively.

    The images will cover the entire screen. If you want them to show some transparency (like the default ones) you must use a file format supporting alpha information (.dds, .png or .tga).


    INTERNAL PARAMETERS


    The following internal parameters can be accessed by using a Script object.

  • Remapping In Progress, read only. This value is 1 when the user is remapping the controls, zero otherwise.