fork download
  1. Subject: [PATCH] Increase max weapon count to 8
  2.  
  3. ---
  4. LIB/GameState.py | 2 +-
  5. LIB/Scorer.py | 8 +++++---
  6. SCRIPTS/GotoMapVars.py | 4 ++--
  7. 3 files changed, 8 insertions(+), 6 deletions(-)
  8.  
  9. diff --git a/LIB/GameState.py b/LIB/GameState.py
  10. index 4af27c2..3c02030 100644
  11. --- a/LIB/GameState.py
  12. +++ b/LIB/GameState.py
  13. @@ -340,7 +340,7 @@ class EntityPersonState(EntityBipedState):
  14. for name in Actions.GetListOfObjectsAt(inv,i):
  15. self.Inventory["Objects"].append(name)
  16.  
  17. - self.Inventory["maxWeapons"]=inv.maxWeapons
  18. + self.Inventory["maxWeapons"]=inv.maxWeapons=8
  19. self.Inventory["Weapons"]=[]
  20. for i in range(inv.nWeapons):
  21. self.Inventory["Weapons"].append(inv.GetWeapon(i))
  22. diff --git a/LIB/Scorer.py b/LIB/Scorer.py
  23. index 22a69ae..cae5062 100644
  24. --- a/LIB/Scorer.py
  25. +++ b/LIB/Scorer.py
  26. @@ -192,6 +192,8 @@ def SetEnemiesData(pj):
  27.  
  28. __wNULL=BUIx.CreateNULLWidget()
  29. char=Bladex.GetEntity("Player1")
  30. +inv=char.GetInventory()
  31. +inv.maxWeapons=8
  32.  
  33.  
  34.  
  35. @@ -616,9 +618,9 @@ wEnemiesFrame.AddWidget(wEnemyRight,E_ICON_DISTANCE*5+2*E_CENTRAL_DISTANCE+E_ARR
  36. wEnemyRight.SetAlpha(1.0)
  37. wEnemyRight.SetColor(255,255,255)
  38.  
  39. -
  40. -RInitAlpha=[1.0,0.3,0.2,0.1,0.05]
  41. -RInitPositions=[(5,10),(35,20),(75,30),(110,40),(140,50)]
  42. +# Add enough right hand slots
  43. +RInitAlpha=[1.0,0.3,0.2,0.1,0.05] + [0.05] * 10
  44. +RInitPositions=[(5,10),(35,20),(75,30),(110,40),(140,50)] + [(140,50)] * 10
  45. wRightHand=ScorerWidgets.B_HandWidget(wFrame,"RightHand",150,150,"Right",
  46. RInitAlpha,RInitPositions)
  47. LInitAlpha=[1.0,0.3,0.2,0.1]
  48. diff --git a/SCRIPTS/GotoMapVars.py b/SCRIPTS/GotoMapVars.py
  49. index c482982..b6732bd 100644
  50. --- a/SCRIPTS/GotoMapVars.py
  51. +++ b/SCRIPTS/GotoMapVars.py
  52. @@ -42,7 +42,7 @@ class MainCharState(GameState.EntityPersonState):
  53. for name in Actions.GetListOfObjectsAt(inv,i):
  54. self.Inventory["Objects"].append(self.__GetObjAux(name))
  55.  
  56. - self.Inventory["maxWeapons"]=inv.maxWeapons
  57. + self.Inventory["maxWeapons"]=inv.maxWeapons=8
  58. self.Inventory["Weapons"]=[]
  59. for i in range(inv.nWeapons):
  60. self.Inventory["Weapons"].append(self.__GetObjAux(inv.GetWeapon(i)))
  61. @@ -246,7 +246,7 @@ def RestoreMainCharState(key):
  62. props[2]["InvRight"] = None
  63. props[2]["InvRightBack"] = None
  64. props[2]["InvLeftBack"] = None
  65. -
  66. +
  67. CreateMainCharWithProps(props)
  68. return 1
  69. return 0
  70. --
  71. 2.21.0.windows.1
  72.  
  73.  
Runtime error #stdin #stdout #stderr 0.01s 5644KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
./prog.sh: line 1: Subject:: command not found
./prog.sh: line 3: ---: command not found
./prog.sh: line 4: LIB/GameState.py: No such file or directory
./prog.sh: line 4: 2: command not found
./prog.sh: line 5: 8: command not found
./prog.sh: line 5: LIB/Scorer.py: No such file or directory
./prog.sh: line 6: 4: command not found
./prog.sh: line 6: SCRIPTS/GotoMapVars.py: No such file or directory
./prog.sh: line 7: syntax error near unexpected token `('
./prog.sh: line 7: ` 3 files changed, 8 insertions(+), 6 deletions(-)'