Urban Terror Forums: [Bug] +vstr malfunctions if another +vstr bind is used at its duration [and possible fix] - Urban Terror Forums

Jump to content

 Login | Register 
Advertisement
Page 1 of 1
  • You cannot start a new topic
  • This topic is locked

[Bug] +vstr malfunctions if another +vstr bind is used at its duration [and possible fix] Rate Topic: -----

#1 User is offline   mitsubishi Icon

  • Account: mitsubishi
  • Country:
  • Joined: 28-February 10
  • Posts: 13,481

Posted 25 February 2010 - 12:58 PM

Thanks to ObScUrE and illmatic (here http://forums.urbant...post__p__257370) I believe there's been discovered a bug with +vstr:

+vstr has a check on the case of release(of the key) to avoid firing the release when bringing down the console; but that check causes the feature to malfunction if you press another +vstr bind at the duration of the first.

original source part:
                case '+':
                        v = Cvar_VariableString( Cmd_Argv( 1 ) );
                        pushed = qtrue;
                        break;
                case '-':
                        // we check this because otherwise key release would fire even in the console...
                        if(pushed) { 
                                v = Cvar_VariableString( Cmd_Argv( 2 ) );
                                pushed = qfalse;
                       }
                        break;

Example of malfunction: [Below in a reply by Nexu]


A potential solution is to remove the 'pushed' check altogether or i suppose if one wants to keep the feature, a more dynamic approach may be required to save several such binds' "pushes".



EDIT: The workaround of removing the 'if pushed' check altogether appears to be working fine.

This post has been edited by mitsubishi: 26 February 2010 - 07:44 AM


#2 User is offline   Delirium Icon

  •   QA member   
  • Account: delirium
  • Country:
  • Joined: 28-February 10
  • Posts: 5,416

Posted 25 February 2010 - 06:55 PM

I dont think its bugged at all
pretty much 95% of my keys are +vstr's and ive never had a problem so I doubt its bugged

#3 User is offline   mitsubishi Icon

  • Account: mitsubishi
  • Country:
  • Joined: 28-February 10
  • Posts: 13,481

Posted 25 February 2010 - 08:56 PM

View PostDelirium, on 25 February 2010 - 06:55 PM, said:

I dont think its bugged at all
pretty much 95% of my keys are +vstr's and ive never had a problem so I doubt its bugged

I've confirmed it and I've workarounded it; I'm pretty sure it's there.

You probably use binds that wouldn't care about it. e.g. I didn't notice at all till those guys mentioned it.

#4 User is offline   Nexu Icon

  •   clan leader   
  • Account: nexu
  • Main tag: |it|
  • Country:
  • Joined: 26-June 07
  • Posts: 4,265

Posted 26 February 2010 - 04:27 AM

View PostDelirium, on 25 February 2010 - 06:55 PM, said:

I dont think its bugged at all
pretty much 95% of my keys are +vstr's and ive never had a problem so I doubt its bugged

No, the bug Fateswarm pointed out does exist.

#5 User is offline   mitsubishi Icon

  • Account: mitsubishi
  • Country:
  • Joined: 28-February 10
  • Posts: 13,481

Posted 26 February 2010 - 05:30 AM

it might require certain types of +vstr scripts; not certain if it occurs in the simplest of them.

bullet_loaderAdvertisement

#6 User is offline   Nexu Icon

  •   clan leader   
  • Account: nexu
  • Main tag: |it|
  • Country:
  • Joined: 26-June 07
  • Posts: 4,265

Posted 26 February 2010 - 07:36 AM

View Postmitsubishi, on 26 February 2010 - 05:30 AM, said:

it might require certain types of +vstr scripts; not certain if it occurs in the simplest of them.

Happens when you call another script while another +vstr script is active. Here is an example how to reproduce this 'problem':

set cg_fov "110" // standard value for this test

set do_zoom_on          "ut_zoomin;    cg_fov 90;  set do_zoom vstr do_zoom_off"
set do_zoom_off   	"ut_zoomreset; cg_fov 110; set do_zoom vstr do_zoom_on"

set do_crouch_on        "+movedown; set do_crouch vstr do_crouch_off"
set do_crouch_off 	"-movedown; set do_crouch vstr do_crouch_on"

bind MOUSE2 "+vstr do_zoom_on do_zoom_off"
bind ALT "+vstr do_crouch_on do_crouch_off"


Test sequence:
  • Press and hold mouse2 button
  • Press ALT and release it
  • Release mouse2 button

Result: FOV is still 90
Expected result: FOV should go back to 110

This post has been edited by Nexu: 26 February 2010 - 07:36 AM


#7 User is offline   mitsubishi Icon

  • Account: mitsubishi
  • Country:
  • Joined: 28-February 10
  • Posts: 13,481

Posted 26 February 2010 - 07:42 AM

ty. i'll put this reply as a better example on the 1st post.

#8 User is offline   slackin Icon

  • Account: slackin
  • Main tag: GlaD-
  • Country:
  • Joined: 28-February 10
  • Posts: 3,888

Posted 01 June 2010 - 05:52 PM

now, what if you were using three of them at once, like laser script with crouch script with fov script? would it still work, im not positive but it looks like that would max at two?
[img]http://i188.photobuc...n35/urt/sig.jpg[/img]
/*----------------------------------------------------------------------
All normal mapped(bump mapped) and specular mapped .|^|.
Just a few of many, and more to come.
----------------------------------------------------------------------*/

Page 1 of 1
  • You cannot start a new topic
  • This topic is locked

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users

Advertisement


Copyright © 1999-2024 Frozensand Games Limited  |  All rights reserved  |  Urban Terror™ and FrozenSand™ are trademarks of Frozensand Games Limited

Frozensand Games is a Limited company registered in England and Wales. Company Reg No: 10343942