Loading

Paste #pitysbpfe

  1. diff -r a5e2fda0b31a nml/actions/action2var.py
  2. --- a/nml/actions/action2var.py Tue Sep 09 13:21:01 2014 +0200
  3. +++ b/nml/actions/action2var.py Tue Sep 09 13:38:47 2014 +0200
  4. @@ -958,6 +958,7 @@
  5.      func60x = lambda value, pos: expression.FunctionPtr(expression.Identifier(generic.reverse_lookup(vars_60x, value), pos), parse_60x_var, value)
  6.  
  7.      return expr.reduce(extra_dicts + [(action2var_variables.varact2_globalvars, parse_var), \
  8. +        (action2var_variables.varact2_globalvars60x, func60x), \
  9.          (vars_normal, parse_var), \
  10.          (vars_60x, func60x)] + \
  11.          global_constants.const_list)
  12. diff -r a5e2fda0b31a nml/actions/action2var_variables.py
  13. --- a/nml/actions/action2var_variables.py       Tue Sep 09 13:21:01 2014 +0200
  14. +++ b/nml/actions/action2var_variables.py       Tue Sep 09 13:38:47 2014 +0200
  15. @@ -112,6 +112,10 @@
  16.      'current_year'         : {'var': 0x24, 'start':  0, 'size': 32},
  17.  }
  18.  
  19. +varact2_globalvars60x = {
  20. +    'CALL' : {'var': 0x7E, 'start': 0, 'size': 15}, #value_function: <read var 0x1C>, param_function: <convert switch to integer>
  21. +}
  22. +
  23.  #
  24.  # Vehicles (features 0x00 - 0x03)
  25.  # A few variables have an implementation that differs per vehicle type

Comments