Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Spiller
16
The easiest way should be

Code: [Select]
table["d"] <- 4

You can also use table.rawset
http://www.squirrel-lang.org/squirreldoc/reference/language/builtin_functions.html#table.rawset
17
General Discussion / Re: Vcmp-desync bug/false ban
« on April 3rd, 2021, 04:53 PM »
I'm not sure if that false ban case is relevant to this forum. But since you mentioned the Gynla case I'd like to drop a few cents. I am convinced that no one is interested here about who is biased towards whom and skimming through a bunch of private messages.

First of all, if you think that was a bug, report it in the correct section along with a plausible way to reproduce it, the videos you showed are completely different to what apparently you were banned for.



And lets not compare a low latency player to a high latency player when you are talking in terms of sync and damage in two different scenarios.

You literally got hit in the video, you were pushed back by the shotgun and received no damage at all, while there was no knockback in Gynla's case that occurred at TDW (which is similar to the other videos that you showed). Whereas I'd consider the video on Gohan pretty normal on a perfect day in VCMP given that he has a 250+ ping.

That, my friend, is a pretty rare bug that happens sometimes where you shoot a player out of his FOV and bullets never appear on their screen. It took me an ugly amount of time to reproduce it back in the day.


https://www.youtube.com/watch?v=pxK_gnPCm8Y

Here is a link to that topic, another identical case is also listed there.



I'm not going to comment on who used a hack, what reputation one stands at and who did what in the past because I'll end up with a book equivalent in length to Sun Tzu's Art of War if I ever came to it. But it seems pretty clear to me that no civilized person would perform such a stunt that you did right here.

You won't achieve anything trying to "expose" someone here. And no, I don't think such a bug exists, if you get knocked back you'll receive damage unless you are immune through a hack or the script.

Also, DizzasTeR summed up the lag situation pretty nice already.

Well Said, Locked (Dizz)
18
Scripting and Server Management / Re: Custom game map (GUI)
« on March 18th, 2021, 12:21 PM »
This is happening because the map (in world) is bigger than your sprite.

Thanks to SpitFire for this information, The map starts from Vector2(-1550, -1950) and ends at Vector2(1550, 1950) i.e 3100 x 3900 in size compared to your 1024 x 1024 sprite.

Here's a visualization:
(click to show/hide)

To fix this, you have 2 methods,

First would be to use a map that is 3100px x 3900px in dimension.

Second is, you scale down coordinates of the map to match your sprite's dimensions. If your sprite is 1024x1024, you'd require to divide player.Pos.x by 3100 / 1024 = 3.027 and player.Pos.y by 3900 / 1024 = 3.8085 (approx).

for instance, if the position of your player is Vector3(832.0377, -459.89297, 2014.9727) the position on map would be X 832.0377/3.027 and Y -459.89297/3.8085 i.e Vector2(274.8720, -120.75435)



I hope this helps, I'm not sure about anything but this should technically work as long as all the variables I took were correct.

* Do note that in both cases, the (0, 0) of your sprite should fall exactly on (-1550, -1950) of the map, otherwise it will not be accurate. In other words, you'll need an accurate representation of the map.
19
Off-Topic General / Re: TCP Gaming Forum
« on February 3rd, 2021, 05:35 AM »
KillerX:

20
Bugs and Crashes / [Bug] Animation bug: Sitting on bikes while crouched
« on January 23rd, 2021, 04:31 AM »
Description
If you try to sit on a bike using the passenger key while crouched, you'll enter and sit in the same state. It might hold some resemblance to this bug.

Reproducible
Always

Steps to reproduce
  • Crouch near the rear tire of bike facing the front.
  • Press the passenger key.

What you were doing when the bug happened
Playing EGAD, Xobert pointed it out as "the cool thing".

What you think caused the bug
-

Video

https://youtu.be/w19iqFC8SfI



P.S The second (sliding) thing may or may not be a bug, it might be caused due to the tire somehow getting stuck in the ground, possible through the sidewalk.

I couldn't reproduce it again, so I assume it's just a VC bug, however I've put it in the video, just incase.

21
Tutorials / [Guide] Latency, Bufferbloat and Jitter
« on January 20th, 2021, 10:40 AM »
Hey everyone,

I don't seem to be having a rationale to why I'm writing this, just in hopes that it might help a few people. Although a big chunk of this thread is from something I posted back in 2016 at some other community, I've tried to update it and make it relevant to VCMP.

This thread entails about basic overview of Latency, Bufferbloat & its impact and a few advices/methods that can be devised to resolve the discussed issues.



— Jibber-Jabber

I'll throw in a few definitions here to reference them in other parts. Most of you might know about them already but anyway,

(a) Bandwidth
It is the maximum rate of data transfer. It can be seen as the "width" of a pipe, the narrower the pipe, the less material can be transferred across it.

(b) Latency
It is "response speed" of your network, measured as the round trip from your game client to the server. It is measured as Ping. The higher the latency, the higher will be the delay between your client and the server or otherwise known as "Lag".

(c) Jitter
This is the measurement of how much your ping is spiking / fluctuating over an average period of time. This can be caused by an inconsistent network or high usage of bandwidth. Higher jitter results into stuttering of your packets, degrading both your and your opponent's gameplay.



— Factors affecting lag

It is a common misconception that only ping has an impact on an individual's lag, while it depends upon a number of other factors, such as jitter, bufferbloat, quality, speed, routing, yadda yadda. Let's discuss a few before we can mitigate them.

(a) Ping
This is obviously the primary factor but not the only. Higher ping means higher delay on all of your actions requiring you to lead your aim on your opponent and also harder for your opponent to hit you.

There are not a lot of ways you can reduce your base ping except changing/upgrading your connection.
(The best would moving closer to the host but it can only be assessed theoretically)

(b) Instability
This causes jitters, stuttering and UDP packets getting lost often. This might vary on strength and bandwidth of your connection.

You might be able to control your network and mildly optimize your connection but in the end its completely dependent upon the architecture of your ISP.

(c) Higher Usage
There might be unwanted processes running in the background consuming your internet such as updates. And there can be a lot of devices connected to your network leeching off bandwidth and making you lag.

(d) Routing
There is a fair chance of misconfiguration by your ISP or at the server which can lead to higher latency. However, these are often temporary.

Another case can occur where the host server is not well optimized in terms of code, there might be a lot of resource consumption due to, for instance, a large number of timers causing the server to not operate at optimum performance. Client side processes can also rupture connectivity.

(e) Speed
I would not rank it as an important factor, because most (urban) connections can meet the basic requirement. However, yes it is a factor, without adequate speed, you're only getting a minimal amount of throughput.



— Bufferbloat & Jitter

This is a factor I'd like to separately highlight in this thread.

What is bufferbloat?
Bufferbloat.net defines it as "the undesirable latency that comes from a router or other network equipment buffering too much data" i.e there are way too many packets sent and they get queued which leads to ping spikes, stuttering and packet loss.

This page right here gives a neat illustration of how data accumulates as buffer.

How do I know if I have this problem?
You can test on DSL Reports, here. Anything below B in Buffer Bloat and we are talking unhittability, which can nowhere be condoned.

Can this be fixed?
Yes, the easiest method to fix it is the rate limit method. However, you'd require a router which allows you to limit bandwidth for a specific device (or total bandwidth). Otherwise you might want to buy switches or other equipment which provide that interface.

Below is a result without capping my bandwidth:
(click to show/hide)

After I limited bandwidth for my PC
(click to show/hide)




A test in-game
(click to show/hide)


20 checks over 40 seconds, Client Response calculated with a threshold of 30ms.

Lower rate, lower bloat
(click to show/hide)

Notes:
A lower rate might result into a low bloat, but you need to maintain a balance at a point where your data is getting through at just fine speed while not getting buffering your network at the same time.

You also need to limit other devices on the network otherwise its not a significant change.

Some routers already come with QoS features, you can use them instead to let the router automatically manage bloat.



— Advices to reduce lag

As I said, lag does not depend on a single factor, and there is more than just bufferbloat or ping. So here are some advices that might result into a better gameplay experience.

(a) Wired Connection
If possible, always play on an ethernet connection, it is infinitely better than WiFi, especially 2.4 Ghz band. Mobile networks have a very high packet loss, devoid them from online gaming.

Moreover, there is less bloat, with minimum limit on rate.
(click to show/hide)

(b) Disable Windows Update
Updates in background are outright annoying while gaming, your ping will spike like crazy. You can either disable updates entirely, (DO NOT DO THIS! This is incredibly stupid and a security risk! Updates are required to maintain system stability and security.) or set your network as metered in network settings (Windows 10).

* Game Mode in Windows 10 restricts background internet activity.

(c) Using a game booster
You can use a game booster such as Razer Cortex which not only optimizes your rig for maximum performance but also shuts down background processes which might be consuming internet.

If you don't want to install one, you can still manually close any background process. To find out what is consuming your internet you can use the Task Manager (Win 8+) or Resource Monitor in 7.

(d) Wireless Advices
If you still plan to choose WiFi, or can not use a wired connection, you can atleast improve your wireless connection.

Choosing the best channel
(click to show/hide)
Your router automatically chooses a wifi channel for you to broadcast the signal on. However, it might not the best one.

To figure out which is the best one depending on other networks around you, you can use a WiFi tool such as WifiInfoView by NirSoft.

You have to select the least common channel in your area so it does not clash with any other.

Getting the best out of it
(click to show/hide)
Make sure you have disabled power saving for your network cards in network settings.

For this, go to Network and Sharing Center > Adapter Settings > WiFi > Properties > Configure > Power Management and uncheck "Allow the computer to turn off this device"


You might also reach there from device manager.

You also need to put your WiFi cards in full performance.

For this, go to Power Options > Change Plan Settings > Change Advanced Power Settings > Wireless Adapter Settings and set it to Max Performance


(e) DNS
Your ISP provides you with a DNS which is used to look up and resolve IP addresses. However you might change to public DNS by Google or Cloudflare which are faster.

(f) Flush the Network Profile
Sometimes you need to reset your network config.

Here's how
(click to show/hide)
Open Command Prompt as admin.
Type in the following one by one.

ipconfig /flushdns
ipconfig /registerdns
ipconfig /release
ipconfig /renew
netsh winsock reset


and restart your computer

(g) Change ISP?
You might require to change your ISP if you are not getting the ping you expect to get even after doing everything you could.

You can head over to Global Ping Stats, and check for the ping from your closest source to server location. If your ping is not around the ping calculated there, its time to upgrade or change.

(click to show/hide)



     - These advices are for Windows.
     - There is only so much you can damage in your router, however, be careful.
     - If I got anything wrong or something can be improved/added, feel free to contact or correct me.

22
I always thought that this is because of ping and their differences, turns out it also happens on localhost.

I recorded a video of the above, if it's any help to this case.
Obviously I'm not very fast but I still tried my best.


https://www.youtube.com/watch?v=dpvaamOLBTM

Videos were recorded on 30FPS, however, frame limiter does not seem to effect the outcome.
Nor does the code provided by Seby. (After 1:09 in the video, the snippet was in effect)

(click to show/hide)
Can you test this with your DM skills, and record the same way ?

Code: [Select]
function onPlayerCrouchChange( player, IsCrouchingNow )
{
if( !IsCrouchingNow ) player.SetAnim( 0, 29 );
}





EDIT: lol Hunting, I like you are dedicated to what you've discovered but whatever you threw above is the surest way to ravage this topic.
23
Script Showroom / [Tool] Re: Script Compiling Tool
« on December 11th, 2020, 11:56 AM »
Quote from DizzasTeR on December 11th, 2020, 09:08 AM
Nice work.

As a bonus provide a parameter or a way to retain the actual file extension as nut even once compiled. Some people (including myself) just like to keep the file extension same for my compiled files.
Thanks,
Added support for extensions, compiled files will have whatever extension you provide in extension.ini. (both client and server side)
24
Script Showroom / [Tool] Script Compiling Tool
« on December 11th, 2020, 08:36 AM »
What and why?

This is the result of accidentally locking myself in my room and ultimate boredom ):
This might not really be useful to a lot of people but helpful for anybody who compiles their scripts (at either server or client side) as compiled nut (cnut) files.

Highlights:
  • Compiles all files in one click, no configuration required.
  • Directory structure is retained.
  • Errors from all files are displayed after compiling.
Instructions

Preview:

(click to show/hide)
(click to show/hide)
(click to show/hide)


Links:

Virus Report.
GitHub Repository.
Download.
25
Support / Re: Question about player's marker
« on November 27th, 2020, 03:45 AM »
Quote from Kenneth Law on November 27th, 2020, 12:55 AM
I've tried the way similar to the codes you gave, but there is still another problem which is the limitation of number of markers you can create in VCMP server. It has a restriction of 100. Give the example that 10 players are in server, in which I might have to create 9 markers for each player. That's totally 90 markers already. It could be insufficient for me to use.
Totally, that's why I mentioned this is not much of a solution.
Besides Doom already stated that this can't be done exactly how you want it to be.
26
Support / Re: Question about player's marker
« on November 26th, 2020, 11:15 AM »
This is not much of a solution but you can do something like this. (but at what cost?)


https://youtu.be/Gzskg2PrZT0

Code
Code: [Select]
SetShowOnRadar(false);
enum MARKER_CONFIG
{
RADIUS = 50, // Radius in which markers will be visible
UPDATE_TIME = 1000 // Markers are updated at this rate (ms)
};

PlayerIDs <- [];
MarkerData <- array(GetMaxPlayers(), null);

class MarkerClass
{
playerID = 0;
Marker = null;

Markers = null;
HasMarker = null;

constructor(pID)
{
this.playerID = pID;

Markers = [];
HasMarker = [];
}

function HasMarkerFor(pID)
{
if(this.HasMarker.find(pID) == null)
return false;

return true;
}

function CreateMarkerFor(pID)
{
local player = ::FindPlayer(this.playerID), target = ::FindPlayer(pID);
if(!player || !target) return 1;

local NewMarker = ::CreateMarker(player.UniqueWorld, target.Pos, 3, target.Colour, 0);
this.Markers.append(NewMarker);
this.HasMarker.append(pID);
}

function RemoveMarkerFor(pID)
{
local Position = this.HasMarker.find(pID);
if(Position == null) return 1;

::DestroyMarker(this.Markers[Position]);
this.Markers.remove(Position);
this.HasMarker.remove(Position);
}

function Destroy()
{
foreach(val in this.Markers)
::DestroyMarker(val);

this = null;
}
}

function MarkerHandler()
{
foreach(i, Entity in PlayerIDs)
{
local player = FindPlayer(Entity);
if(player)
{
foreach(Entity_ in PlayerIDs)
{
if(Entity_ == Entity)
continue;

if(CheckRadius(Entity, Entity_))
{
if(!MarkerData[Entity].HasMarkerFor(Entity_))
MarkerData[Entity].CreateMarkerFor(Entity_);
}
else
{
if(MarkerData[Entity].HasMarkerFor(Entity_))
MarkerData[Entity].RemoveMarkerFor(Entity_);
}
}

foreach(i, Marker in MarkerData[Entity].Markers)
{
DestroyMarker(Marker);

local target = FindPlayer(MarkerData[Entity].HasMarker[i]);
if(!target) return 1;

CreateMarker(player.UniqueWorld, target.Pos, 3, target.Colour, 0);
}
}
}
}
NewTimer("MarkerHandler", MARKER_CONFIG.UPDATE_TIME, 0);

function CheckRadius(Entity, Entity_)
{
local p1 = FindPlayer(Entity),
p2 = FindPlayer(Entity_);

if(p1 && p2)
{
if(!p1.IsSpawned || !p2.IsSpawned) return false;

if(sqrt(((p1.Pos.x - p2.Pos.x)*(p1.Pos.x - p2.Pos.x)) + ((p1.Pos.y - p2.Pos.y)*(p1.Pos.y - p2.Pos.y))) < MARKER_CONFIG.RADIUS)
return true;
}

return false;
}

onPlayerJoin
Code: [Select]
function onPlayerJoin( player )
{
PlayerIDs.append(player.ID);
MarkerData[player.ID] = MarkerClass(player.ID);
}

onPlayerPart
Code: [Select]
function onPlayerPart( player, reason )
{
PlayerIDs.remove(PlayerIDs.find(player.ID));
MarkerData[player.ID].Destroy();
}

Hastebin, if the formatting in above code appears messed up.

P.S. Didn't test much.
27
Script and Content Requests / Re: Server Problem Fix it.
« on October 26th, 2020, 10:23 AM »
Check if your ports are properly forwarded,
Use Thijn's Connection Checker to confirm.

(if you don't know your IP address, just Google, "my IP address")
28
Servers / [0.4] The Demolition Wars
« on October 20th, 2020, 06:52 AM »



The Demolition Wars
Releasing 24th October
49.12.15.63:8192



We are happy to finally announce release date for our server.
Save this date! Saturday 24th of October at 15 GMT.
After dedicating 3+ months of time into the server, we are glad that everything has been put in place.




The development does not stop here, we will keep adding new features constantly to the server.
Together with the release, staff applications will be opened to public for numerous ranks.

Read More...



29
General Discussion / Re: VCMP Client on linux
« on October 6th, 2020, 07:33 AM »
so it actually worked?
Back in the day I tried booting it up on Linux but could not get it to work with wine.