Sauerworld Forum

Saw hudgun

Alu

  • *
  • 43
  • +2/-0
Saw hudgun
« on: September 18, 2015, 09:48:13 PM »
i have no idea what I'm doing

but the idea is that when you have the saw the hudgun is turned on

at least I'm close to achieving something  :o ??


cierrahudgun = [cierra; cierraon; cierraoff]

cierra = [ sleep 10 [if (&& (= (getweapon) 7) (= contador 1)) [hudgun 1]] cierra ]
cierraon = [ sleep 9 [if (= (getweapon) 7) [contador = 1]] cierraon ]
cierraoff = [ sleep 8 [if (&& (= contador 1) (!= (getweapon) 7)) [contador = 0]] cierraoff ]

cierrahudgun


umm I suspect the problem is with the "contador = 1, contador = 0"     the counter

Quality

  • *
  • 34
  • +0/-0
  • Guitarthusiest :P
Re: Saw hudgun
« Reply #1 on: September 19, 2015, 07:46:29 AM »
Everywhere you want to get the value of contador, you need to use '$'.
E.g.
Code: [Select]
if (= $contador 1) ...I think it should work then.

Alu

  • *
  • 43
  • +2/-0
Re: Saw hudgun
« Reply #2 on: September 19, 2015, 06:54:19 PM »
with more common sense:

------
contador = 1

cierra = [if (&& (= (getweapon) 7) (= $contador 1)) [hudgun 1] [hudgun 0]]

cierra
----------

why the hell does not work? :'v

It did not work as it was before
and it does not work now
« Last Edit: September 19, 2015, 06:57:22 PM by Alu »

Alu

  • *
  • 43
  • +2/-0
Re: Saw hudgun
« Reply #3 on: September 19, 2015, 07:56:02 PM »
dont know wheres the problem with my linear code ¿?

copying and passing the structure of another in my config (ardelico weapons sens)
this works well :) :

--------------------------

cierrahudgun = [cierra]
escopetahudgun = [escopeta]

cierra = [
        sleep 5 [
                if (= (getweapon) 0) [hudgun 1] [hudgun 0]             
        ] cierra
]

escopeta = [
        sleep 5 [
                if (= (getweapon) 1) [hudgun 1] [hudgun 0]             
        ] escopeta
]

cierrahudgun
escopetahudgun

-------------------------

the game does not like the linear code :v ?

I find it very confusing if he is not linear

Alu

  • *
  • 43
  • +2/-0
Re: Saw hudgun
« Reply #4 on: September 19, 2015, 09:51:58 PM »
haha still not working


I think that this fixed:

cierrahudgun = [armas]

armas = [
        sleep 5 [
                if (|| (= (getweapon) 1) (= (getweapon) 0)) [hudgun 1] [hudgun 0]             
        ] armas
]

cierrahudgun

frosty

Re: Saw hudgun
« Reply #5 on: September 21, 2015, 01:14:12 AM »
try clearing configs

Alu

  • *
  • 43
  • +2/-0
Re: Saw hudgun
« Reply #6 on: September 21, 2015, 02:59:47 AM »
try clearing configs


No, it was not that, was the syntax the [] and () spaces or something
- I have always clean the config file


this works well:

----------------------------------------------------------
weaphudguns = [weapons]

Weapons = [
         sleep 5 [
                 if (|| (= (getweapon) 1) (= (getweapon) 0)) [hudgun 1] [hudgun 0]
         ] weapons
]

weaphudguns

Suicizer

  • ***
  • 141
  • +6/-5
Re: Saw hudgun
« Reply #7 on: November 22, 2016, 04:21:49 PM »
Why are you guys using "weaphudsguns", while "weapons" is the exact same thing in the script?

RaZgRiZ

  • *
  • 12
  • +0/-1
Re: Saw hudgun
« Reply #8 on: December 06, 2016, 03:44:54 PM »
I don't think they even know what they're trying to do in the first place.

star

  • *****
  • 310
  • +19/-5
Re: Saw hudgun
« Reply #9 on: December 06, 2016, 03:47:48 PM »
nice necro bumps.

[closed]