PDA

View Full Version : developing an rts script



shamanik
08-04-2011, 05:53 AM
hi, i already set up most everything but i want to tweak a few things, im making this a default pointer script so that i wont have to individually add rts games; but im making this script particularly for command and conquer 3 and kanes wrath expansion. ill need to edit out some of the controls for more useful things but thats not too much of a problem. i have most every button mapped to something useful. anyways my problems are -

1. how do u add page up and page down keys to a script? is it pgup pgdn? or page_down or what?

2. as u see i put the mouse wheel up and down set for right controller button 2 and 4. only problem is i have to keep pressing repetitively to zoom in and out of the battlefield. how do i make this a complex binding that will repeat say every quarter or half of a second?

3. any other pointers would help too.

remember this is a default script so if u dont want to override ur own change its filename before moving it and setup its exe and windows name.

thanks!

Danny
08-04-2011, 12:01 PM
1. how do u add page up and page down keys to a script? is it pgup pgdn? or page_down or what?
pageup
pagedown


2.how do i make this a complex binding that will repeat say every quarter or half of a second?



<binding>
<conditions>
<button>
<controller>P1R</controller>
<which>2</which>
</button>
</conditions>
<actions>
<mouse_wheel>
<direction>up</direction>
<repeat>true</repeat>
<repeat_on_duration>250</repeat_on_duration>
</mouse_wheel>
</actions>
</binding>


<binding>
<conditions>
<button>
<controller>P1R</controller>
<which>4</which>
</button>
</conditions>
<actions>
<mouse_wheel>
<direction>down</direction>
<repeat>true</repeat>
<repeat_on_duration>250</repeat_on_duration>
</mouse_wheel>
</actions>
</binding>



3. any other pointers would help too.
Replacing the default.mce is probably not a great idea. You could rename it to genericRTS.mce and just keep adding new exe names for supported games:

for example:


<game_list>
<game>
<version>1.0</version>
<requires_schema_version>1.0</requires_schema_version>




<exe_name>Sun.exe</exe_name>


<exe_name>age-of-empires-3.exe</exe_name>

<full_name>Generic RTS MCE</full_name>
<controller_manager_mode>1P2C</controller_manager_mode>

shamanik
08-11-2011, 10:46 PM
heres the updated version with your scroll thing u taught me. its still a default but if u want to use it particularly for a certain game just copy and paste it. it works for command and conquer generals and zero hour expansion and command and conquer 3 and kanes wrath expansion. plus all ur stuff for surfing is there.