Scripts / Script Help ( VIdeo Cassette Recorder )

Author
Message
Super Clark
GameGuru TGC Backer
13
Years of Service
User Offline
Joined: 4th Apr 2011
Location: UK
Posted: 26th Feb 2015 16:23
I have been trying to sort a Script for an animated entity VCR

I have managed to get the script to eject the tape from the unit, but i'm stuck
on getting it to insert again but then stay in until you press E again.

I have script set so as to state 'Press E to Eject Tape'
This works just fine and the test shows up on screen.

But I have set a second command for Incert 'Press E to Insert Tape'
this text does not show up on screen when you press E again.

I someone could point me in the right direction and show me were
i am going wrong please.

I have added the script I have done so far

PM
J_C
16
Years of Service
User Offline
Joined: 9th Nov 2007
Location:
Posted: 26th Feb 2015 17:57
I have not had a chance to check out your code...

but a quick glance shows me ... your last if statement

If g_keyPressE == 1 then
vcr_pressed = 0
end

I think it should be

If g_keyPressE == 0 then
vcr_pressed = 0
end

Look at the door script for example...

PM
Super Clark
GameGuru TGC Backer
13
Years of Service
User Offline
Joined: 4th Apr 2011
Location: UK
Posted: 26th Feb 2015 19:35
Got it to work, just not the load tape bit now will keep at it thanks
PM
smallg
Community Leader
18
Years of Service
User Offline
Joined: 8th Dec 2005
Location:
Posted: 26th Feb 2015 21:11
your problem is in this variable you keep swapping
Quote: "vcr_pressed == 1"

in the second state this will be 0 but it checks for 1 (if you change the code as JC says) i think it should look more like this


life\'s one big game

windows vista ultimate

i5 @3.3ghz, 4gb ram, geforce gtx460, directx 11
Super Clark
GameGuru TGC Backer
13
Years of Service
User Offline
Joined: 4th Apr 2011
Location: UK
Posted: 26th Feb 2015 21:19


Me got it sorted thanks guys for the help.
PM

Login to post a reply

Server time is: 2024-05-20 03:36:55
Your offset time is: 2024-05-20 03:36:55