Welcome, Guest. Please login or register.

Login with username, password and session length
 
Pages: [1]
  Print  
Author Topic: Variable switch  (Read 2759 times)
We Are BORG !!!
Specialist
*
Offline Offline

Posts: 95


We Are BORG !!!


« on: November 01, 2010, 10:05:25 PM »

I need a way to make something (a box lets say) unhide when you sit in a chair but hide the next time you sit in it...
I keep trying to think of different methods & I cant think of a way to do it that wouldnt be a "dead man switch" unhides when you sit in chair but as soon as you get up its hidden again.

Anybody have any ideas?
Logged

We Are BORG !!!
We Are BORG !!!
Specialist
*
Offline Offline

Posts: 95


We Are BORG !!!


« Reply #1 on: November 03, 2010, 01:10:03 AM »

Never-mind, I figured it out.

If never() then v1 = 1 endif
Ploop
if v1 == 1 and ssnnearssn(player,132074,1) then unhidessn(66537) ssnrelease(player) inc(v1)
elseif v1 == 2 and ssnnearssn(player,132074,1) then hidessn(66537) ssnrelease(player) dec(v1) endif
End
Logged

We Are BORG !!!
OldMan.
Private First Class
*
Offline Offline

Posts: 72


WWW
« Reply #2 on: November 30, 2010, 05:11:47 PM »

Code:
If never() then
    v1 = 1
endif
Ploop
    if v1 == 1 and ssnnearssn(player,132074,1) then
        unhidessn(66537)
        ssnrelease(player)
        inc(v1)
    elseif v1 == 2 and ssnnearssn(player,132074,1) then
        hidessn(66537)
        ssnrelease(player)
        dec(v1)
    endif
End
why sooo long winded Smiley

Code:
if ssnride(chair) enter
    doseq
        unhidessn(object)
    next
        hidessn(object)
    enddo
endif
Logged

We Are BORG !!!
Specialist
*
Offline Offline

Posts: 95


We Are BORG !!!


« Reply #3 on: December 01, 2010, 10:02:36 PM »

Because I lack the experience....    Is that what the "enter" command is, makes it work like a switch?
Logged

We Are BORG !!!
Slayer
Sergeant Major
****
Offline Offline

Posts: 618


DILLIGAF!


« Reply #4 on: December 02, 2010, 11:48:44 AM »

http://nile.dfreload.com/wiki/index.php?ENTER
« Last Edit: February 15, 2012, 11:02:59 PM by Luke Nadewalker » Logged
Pages: [1]
  Print  
 
Jump to:  





Powered by SMF 1.1.21 | SMF © 2015, Simple Machines
SimplePortal 2.3.2 © 2008-2010, SimplePortal