Author Topic: ULX Observation Mode  (Read 12705 times)

0 Members and 1 Guest are viewing this topic.

Offline Neku

  • Hero Member
  • *****
  • Posts: 549
  • Karma: 27
ULX Observation Mode
« on: May 28, 2014, 08:10:57 PM »
ULX Observation Mode - 1.2

This adds a command into the utility tab called ulx observe. It places the target into Observation Mode, making them noclipped, godded, and invisible. This also stores the target's location and restores it upon reuse. If no target is defined with the chat command, it will target the person calling the command.

I made this for a guy on coderhire, but since it was easy to do, I did it for free.

Link to the job

  • 1.2 - Fixed an oversight on the cloaking amount.
  • 1.1 - Fixed critical bug relating to EyePos and EyeAngles. Also made noclip simpler. (Thanks Cobalt!)
  • 1.0 - Inital Release
« Last Edit: June 07, 2014, 08:50:14 PM by Neku »
Out of the Garry's Mod business.

Offline Cobalt

  • Full Member
  • ***
  • Posts: 216
  • Karma: 44
  • http://steamcommunity.com/id/__yvl/
Re: ULX Observation Mode
« Reply #1 on: May 29, 2014, 12:14:01 PM »
ULX Observation Mode - 1.0

This adds a command into the utility tab called ulx observe. It places the target into Observation Mode, making them noclipped, godded, and invisible. This also stores the target's location and restores it upon reuse.

I made this for a guy on coderhire, but since it was easy to do, I did it for free.

Link to the job

Instead of running a console command just do this:
target_ply:SetMoveType( MOVETYPE_NOCLIP )
and
target_ply:SetMoveType( MOVETYPE_WALK )

Offline Zombine

  • Newbie
  • *
  • Posts: 19
  • Karma: 0
Re: ULX Observation Mode
« Reply #2 on: June 01, 2014, 08:53:36 PM »
Well I finally got around to nagging my server manager to put it in, and when using it I get this:
Code: [Select]
[ERROR] addons/ulx/lua/ulx/modules/sh/observation.lua:12: attempt to call method 'GetEyePos' (a nil value)
  1. call - addons/ulx/lua/ulx/modules/sh/observation.lua:12
   2. __fn - addons/ulib/lua/ulib/shared/commands.lua:943
    3. unknown - addons/ulib/lua/ulib/shared/commands.lua:1296
     4. unknown - lua/includes/modules/concommand.lua:69


Offline Neku

  • Hero Member
  • *****
  • Posts: 549
  • Karma: 27
Re: ULX Observation Mode
« Reply #3 on: June 01, 2014, 09:21:07 PM »
I'll take a look at that, I don't think your eye position is needed anyway.
Out of the Garry's Mod business.

Offline Cobalt

  • Full Member
  • ***
  • Posts: 216
  • Karma: 44
  • http://steamcommunity.com/id/__yvl/
Re: ULX Observation Mode
« Reply #4 on: June 01, 2014, 11:10:27 PM »
I'll take a look at that, I don't think your eye position is needed anyway.
It's not GetEyePos(), just EyePos()

Offline Neku

  • Hero Member
  • *****
  • Posts: 549
  • Karma: 27
Re: ULX Observation Mode
« Reply #5 on: June 01, 2014, 11:21:44 PM »
Alrighty, I fixed that issue up. Thanks Cobalt!
Out of the Garry's Mod business.

Offline Zombine

  • Newbie
  • *
  • Posts: 19
  • Karma: 0
Re: ULX Observation Mode
« Reply #6 on: June 02, 2014, 08:17:17 PM »
Is there any way the weapon could be made invisible, too? Or is that not a possibility with ULX functions?

Offline Neku

  • Hero Member
  • *****
  • Posts: 549
  • Karma: 27
Re: ULX Observation Mode
« Reply #7 on: June 02, 2014, 08:22:37 PM »
They should be invisible too.
Out of the Garry's Mod business.

Offline Zombine

  • Newbie
  • *
  • Posts: 19
  • Karma: 0
Re: ULX Observation Mode
« Reply #8 on: June 04, 2014, 02:33:39 PM »
No, unfortunately the weapons are not invisible. As well, I can still slightly see people in observer mode, almost as if they have the vol_light material on.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: ULX Observation Mode
« Reply #9 on: June 05, 2014, 07:34:08 AM »
Zombine, providing a bit more information would help greatly.
What gamemode? Do you use any addons that would affect the way a player looks visually?
Do you use any addons that do _anything_ with weapons? Is it all weapons, or custom ones? Which ones?
It sounds like this release works, perhaps just not in your server environment due to gamemode and or addon conflict.
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline Zombine

  • Newbie
  • *
  • Posts: 19
  • Karma: 0
Re: ULX Observation Mode
« Reply #10 on: June 05, 2014, 10:13:10 PM »
Sandbox gamemode, no external player modification, and -all- weapons show up. I'm looking through a camera, if that helps, if for any reason cameras don't properly show invisiblity.

Offline Neku

  • Hero Member
  • *****
  • Posts: 549
  • Karma: 27
Re: ULX Observation Mode
« Reply #11 on: June 05, 2014, 11:41:30 PM »
Try running ULX Cloak on yourself and see if the guns still appear.
Out of the Garry's Mod business.

Offline Zombine

  • Newbie
  • *
  • Posts: 19
  • Karma: 0
Re: ULX Observation Mode
« Reply #12 on: June 06, 2014, 06:28:38 PM »
ULX Cloak works just fine, but observer mode does this:



Offline Neku

  • Hero Member
  • *****
  • Posts: 549
  • Karma: 27
Re: ULX Observation Mode
« Reply #13 on: June 07, 2014, 08:48:07 PM »
ULX Cloak works just fine, but observer mode does this:

<snip>

Alright, I overlooked that the amount that would cloak you by was 255 subtracted by the amount.
I fixed this in the update. Hopefully, this will be the last update! (Unless Garry breaks things.)
I don't know about the weapons though.
« Last Edit: June 07, 2014, 08:51:59 PM by Neku »
Out of the Garry's Mod business.

Offline Zombine

  • Newbie
  • *
  • Posts: 19
  • Karma: 0
Re: ULX Observation Mode
« Reply #14 on: June 08, 2014, 07:53:40 PM »
Well whatever you did to the fix the cloaking fixed the weapons issue with it!

It's absolutely perfect now, thank you so much for all of your help!