+Use to open door
I run a zombie server for TS and I have to remove all the doors in order for the players to get into buildings and stuff.
Then a friend recommended a mod that can open the door on +use. We both tried making them but we both failed. This is what I have. Not sure if I did this right... lol. Code:
|
Re: +Use to open door
Code:
Change to the line below. When you put 200 in there, the only time the door will open is if the client is exactly 200 units away from the door. If you want to open the door only when the client is within 200 units of the door, check the distance between the client and door with get_distance. Code:
I don't actually know for sure if this function is case sensitive, but I always write it like this: Code:
Other than that , it looks ok. I don't know if fake_touch is necessary. You can omit the return inside of the if. EDIT: Hawk is right, passing 200 for the distance doesn't do what I thought it did. I didn't test it correctly when I was playing around with it. Sorry about that. |
Re: +Use to open door
Quote:
Quote:
Also, if that doesn't work, try changing the fake_touch/force_use block to this: Code:
|
Re: +Use to open door
well its working, but Im getting spammed in my console and it is also freezing alot.
Code:
L 01/23/2007 - 21:03:06: [ENGINE] Invalid player 0 (not in-game)Code:
|
Re: +Use to open door
Try changing it to the thing I said before.
|
| All times are GMT -4. The time now is 22:24. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.