Jump to content
Eternal Lands Official Forums
Sign in to follow this  
Puntif

Sit/stand Hot Key

Recommended Posts

I've thought there should be a hot key for sit/stand for a very long time. I finally got around to coding it. This is my first attempt at a CVS diff so let me know if I used it correctly. I chose alt-s as the default sit/stand key. My patch also includes a "break;" that appeared to be missing from events.c as well.

 

Index: elc/events.c
===================================================================
RCS file: /cvsroot/elc/elc/events.c,v
retrieving revision 1.73
diff -r1.73 events.c
11a12
> Uint32 last_sit_stand=0;
186a188,197
>                               if (key==K_SITSTAND)
>                                       {
>                                               if(!last_sit_stand || last_sit_stand+500<cur_time)
>                                               {
>                                                       last_sit_stand=cur_time;
>                                                       sit_button_pressed(NULL, 0);
>                                               }
>                                               break;
>                                       }
> 
189a201
>                                               break;
Index: elc/key.ini
===================================================================
RCS file: /cvsroot/elc/elc/key.ini,v
retrieving revision 1.6
diff -r1.6 key.ini
6a7
> #K_SITSTAND = LALT s
Index: elc/keys.c
===================================================================
RCS file: /cvsroot/elc/elc/keys.c,v
retrieving revision 1.4
diff -r1.4 keys.c
14a15
> Uint32 K_SITSTAND=ALT|'s';
94a96,97
>       if((t=get_string_occurance("#K_SITSTAND",file_mem,key_file_size,0))!=-1)
>               K_SITSTAND = parse_key_string(&file_mem[t]);
Index: elc/keys.h
===================================================================
RCS file: /cvsroot/elc/elc/keys.h,v
retrieving revision 1.3
diff -r1.3 keys.h
14a15
> extern Uint32 K_SITSTAND;

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×