[GEN/FUN] Team Crosshairs 1.0a 
11 comments [General / FUN] Crosshairs
To make it short:
You can see your team mates' crosshairs. Cool. (Video)
As spectator you can see everybody's crosshairs. Even cooler.
Special unnecessary feature: you can see your own cursor with the additional network delay. Yay!
Commands:
!crosshairs or !crosshair or !pointer - help message
!crosshairs ghost - (toggle) show your own cursor as image (off by default)
!crosshairs seeteam - (toggle) show your team mates' cursors (on by default)
Installation
Drop crosshairs.lua into /sys/lua/autorun/ folder
Want more features?
Like showing enemy cursors, fancier cursor image and etc? PM me.
Does it cause lag?
It shouldn't unless you're playing from Mars. Cursor images are only updated when needed. Additionally, I've built-in a "lag reducer" for people with >200ms ping (configurable). For them it will only request player data every 100ms (also configurable). For "fast" players with low ping the request are made on
always
In case you want to slow down the requests for all players, set "crosshairs.pingboundary" to 0, so that every player is considered slow.
Limitations
The cursors for spectators will appear laggy because spectators' positions are sent every second or so by CS2D. I think I can't do anything about this
Changelog
1.0a: Fix bug in isfriendly() functions, it didn't work correctly in Deathmatch
PS: I only wonder if this can be really useful for teamwork on construction/zombie servers.
To make it short:

As spectator you can see everybody's crosshairs. Even cooler.
Special unnecessary feature: you can see your own cursor with the additional network delay. Yay!

!crosshairs or !crosshair or !pointer - help message
!crosshairs ghost - (toggle) show your own cursor as image (off by default)
!crosshairs seeteam - (toggle) show your team mates' cursors (on by default)

Drop crosshairs.lua into /sys/lua/autorun/ folder

Like showing enemy cursors, fancier cursor image and etc? PM me.

It shouldn't unless you're playing from Mars. Cursor images are only updated when needed. Additionally, I've built-in a "lag reducer" for people with >200ms ping (configurable). For them it will only request player data every 100ms (also configurable). For "fast" players with low ping the request are made on

In case you want to slow down the requests for all players, set "crosshairs.pingboundary" to 0, so that every player is considered slow.

The cursors for spectators will appear laggy because spectators' positions are sent every second or so by CS2D. I think I can't do anything about this

1.0a: Fix bug in isfriendly() functions, it didn't work correctly in Deathmatch
PS: I only wonder if this can be really useful for teamwork on construction/zombie servers.
edited 6×, last 03.10.16 04:05:41 pm

Comments
11 comments



Log in!
You need to log in to be able to write comments!Log in
05.10.16 10:15:53 pm
Will do. I couldn't do this without a separate crosshair image, so I will have to add one (optional).
Thanks guys!
@
Cure Pikachu: Thanks for telling about string value... I h8
DC for this. That comparison would have always returned true
@




/sys/lua/autorun/
There, fixed your typo.
Definitely a different take from




Though team-based crosshair colors will be nice, at least for spectator mode.



