[GAMEMODE]DeathMatch v1.1

Started by UncleRus, Aug 18, 2020, 04:59 PM

Previous topic - Next topic

UncleRus

Hi guys today I am posting my script that I did with my brothers. This is an update of my earlier script. The plugins needed sqlite04rel32 squirrel04rel32 announce04rel32 hashing04rel32 xmlconf04rel32 I made a script with my brothers on a 32 bit system but you can barter for 64 bit depending on your system. this script I used subscripts For vehicle system thanks to KrloZz, as well as Mohamed's Account System, Sebastian Animation`s pack,Link https://drive.google.com/file/d/1PfUAYk1p1Mf3d842Sk9gDNt1kVvp1Ksa/view?usp=sharing
If you see any error, write here in this topic, we will try to solve.In server storage i put easter egg mini:)
I LoperkinDead.My brothers scripters TimyrSem,VladSem


longhackmc


it didn't work, there was an error with the database

shaddam17

Same database problem here too

SHy^

Post error screenshot & line

shaddam17

Running it on windows 32bit is working now.

UncleRus

I LoperkinDead.My brothers scripters TimyrSem,VladSem

shaddam17

How does the banning system work? It says the player is banned, but he can come back, he only receives a kick

UncleRus

Quote from: shaddam17 on Dec 19, 2020, 07:50 PMHow does the banning system work? It says the player is banned, but he can come back, he only receives a kick
You can take screenshoot this problem?
I LoperkinDead.My brothers scripters TimyrSem,VladSem

shaddam17

Well...


The guy had a mental meltdown. When I banned him it was literally just a kick.He could reconnect with even the same name/UID However there is his uid line in the bans db

[noae]Player 'MuXsT' ID 0 connected.
Player 'Szondikapitany' ID 1 connected.
Disconnecting player 'MuXsT' at ID 0, sent quit packet with reason 1.
Player 'MuXsT' ID 0 disconnected.
Disconnecting player 'Szondikapitany' at ID 1, sent quit packet with reason 1.
Player 'Szondikapitany' ID 1 disconnected.
Player 'Grozav' ID 0 connected.
Player 'Szondikapitany' ID 1 connected.
Disconnecting player 'Szondikapitany' at ID 1, sent quit packet with reason 1.
Player 'Szondikapitany' ID 1 disconnected.
Player 'Szondikapitany' ID 1 connected.
Kicking connecting player at ID 2, name already in use.
Kicking connecting player at ID 2, name already in use.
Kicking connecting player at ID 2, name already in use.
Player 'Szondikapitany.' ID 2 connected.
Player 'Szondikapitany.' ID 2 disconnected (kicked).
Disconnecting player 'Grozav' at ID 0, sent quit packet with reason 1.
Player 'Grozav' ID 0 disconnected.
Player 'Grozav' ID 0 connected.
Disconnecting player 'Grozav' at ID 0, sent quit packet with reason 1.
Player 'Grozav' ID 0 disconnected.
Player 'FatherofSzondi' ID 0 connected.
Player 'FatherofSzondi' ID 0 disconnected (kicked).
Player 'UnfairShit' ID 0 connected.
Player 'UnfairShit' ID 0 disconnected (kicked).
Player 'iKnowyourHouse' ID 0 connected.
Player 'iKnowyourHouse' ID 0 disconnected (kicked).
Player 'iWillVisitYou' ID 0 connected.
Player 'iWillVisitYou' ID 0 disconnected (kicked).
Player 'soon_very_soon' ID 0 connected.
Player 'soon_very_soon' ID 0 disconnected (kicked).
Player 'prepareYour.anus' ID 0 connected.
Player 'prepareYour.anus' ID 0 disconnected (kicked).
Player 'HungarianKid' ID 0 connected.
Player 'HungarianKid' ID 0 disconnected (kicked).
Player 'Noob[Hun' ID 0 connected.
Player 'Noob[Hun' ID 0 disconnected (kicked).
Player 'iRapeYou' ID 0 connected.
Player 'iRapeYou' ID 0 disconnected (kicked).
Player 'DDOS' ID 0 connected.
Player 'DDOS' ID 0 disconnected (kicked).
Player 'dos' ID 0 connected.
Player 'dos' ID 0 disconnected (kicked).
Player 'bitchaaas' ID 0 connected.
Player 'bitchaaas' ID 0 disconnected (kicked).
Player 'Lady' ID 0 connected.
Player 'Lady' ID 0 disconnected (kicked).
Player 'Simpmeister' ID 0 connected.
Player 'Simpmeister' ID 0 disconnected (kicked).
Player 'heizter' ID 0 connected.
Player 'MuXsT' ID 2 connected.
Disconnecting player 'MuXsT' at ID 2, sent quit packet with reason 1.
Player 'MuXsT' ID 2 disconnected.
Player 'arbamoney' ID 2 connected.
Disconnecting player 'arbamoney' at ID 2, sent quit packet with reason 1.
Player 'arbamoney' ID 2 disconnected.
Disconnecting player 'heizter' at ID 0, sent quit packet with reason 1.
Player 'heizter' ID 0 disconnected.
Player 'Dusanbajev' ID 0 connected.
Player 'Dusanbajev' ID 0 disconnected (kicked).
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Player 'KURVAANYAD' ID 0 connected.
Player 'KURVAANYAD' ID 0 disconnected (kicked).
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Player 'DAGADT_GECI' ID 0 connected.
Player 'DAGADT_GECI' ID 0 disconnected (kicked).
Player 'papaszemes' ID 0 connected.
Player 'papaszemes' ID 0 disconnected (kicked).
Player 'Fogyjal_le' ID 0 connected.
Player 'Fogyjal_le' ID 0 disconnected (kicked).
Player 'VRLice' ID 0 connected.
Player 'VRLice' ID 0 disconnected (kicked).
Disconnecting player 'Szondikapitany' at ID 1, sent quit packet with reason 1.
Player 'Szondikapitany' ID 1 disconnected.
Player 'MEGDOGLESZ' ID 0 connected.
Disconnecting player 'MEGDOGLESZ' at ID 0, sent quit packet with reason 1.
Player 'MEGDOGLESZ' ID 0 disconnected.
Player 'Szondikapitany' ID 0 connected.
[/noae]




My solution for now is a windows firewall rule. Not elegant but working

SHy^

#10
Quote from: shaddam17 on Dec 22, 2020, 12:15 AMWell...


The guy had a mental meltdown. When I banned him it was literally just a kick.He could reconnect with even the same name/UID However there is his uid line in the bans db

[noae][noae][noae][noae][noae]Player 'MuXsT' ID 0 connected.
Player 'Szondikapitany' ID 1 connected.
Disconnecting player 'MuXsT' at ID 0, sent quit packet with reason 1.
Player 'MuXsT' ID 0 disconnected.
Disconnecting player 'Szondikapitany' at ID 1, sent quit packet with reason 1.
Player 'Szondikapitany' ID 1 disconnected.
Player 'Grozav' ID 0 connected.
Player 'Szondikapitany' ID 1 connected.
Disconnecting player 'Szondikapitany' at ID 1, sent quit packet with reason 1.
Player 'Szondikapitany' ID 1 disconnected.
Player 'Szondikapitany' ID 1 connected.
Kicking connecting player at ID 2, name already in use.
Kicking connecting player at ID 2, name already in use.
Kicking connecting player at ID 2, name already in use.
Player 'Szondikapitany.' ID 2 connected.
Player 'Szondikapitany.' ID 2 disconnected (kicked).
Disconnecting player 'Grozav' at ID 0, sent quit packet with reason 1.
Player 'Grozav' ID 0 disconnected.
Player 'Grozav' ID 0 connected.
Disconnecting player 'Grozav' at ID 0, sent quit packet with reason 1.
Player 'Grozav' ID 0 disconnected.
Player 'FatherofSzondi' ID 0 connected.
Player 'FatherofSzondi' ID 0 disconnected (kicked).
Player 'UnfairShit' ID 0 connected.
Player 'UnfairShit' ID 0 disconnected (kicked).
Player 'iKnowyourHouse' ID 0 connected.
Player 'iKnowyourHouse' ID 0 disconnected (kicked).
Player 'iWillVisitYou' ID 0 connected.
Player 'iWillVisitYou' ID 0 disconnected (kicked).
Player 'soon_very_soon' ID 0 connected.
Player 'soon_very_soon' ID 0 disconnected (kicked).
Player 'prepareYour.anus' ID 0 connected.
Player 'prepareYour.anus' ID 0 disconnected (kicked).
Player 'HungarianKid' ID 0 connected.
Player 'HungarianKid' ID 0 disconnected (kicked).
Player 'Noob[Hun' ID 0 connected.
Player 'Noob[Hun' ID 0 disconnected (kicked).
Player 'iRapeYou' ID 0 connected.
Player 'iRapeYou' ID 0 disconnected (kicked).
Player 'DDOS' ID 0 connected.
Player 'DDOS' ID 0 disconnected (kicked).
Player 'dos' ID 0 connected.
Player 'dos' ID 0 disconnected (kicked).
Player 'bitchaaas' ID 0 connected.
Player 'bitchaaas' ID 0 disconnected (kicked).
Player 'Lady' ID 0 connected.
Player 'Lady' ID 0 disconnected (kicked).
Player 'Simpmeister' ID 0 connected.
Player 'Simpmeister' ID 0 disconnected (kicked).
Player 'heizter' ID 0 connected.
Player 'MuXsT' ID 2 connected.
Disconnecting player 'MuXsT' at ID 2, sent quit packet with reason 1.
Player 'MuXsT' ID 2 disconnected.
Player 'arbamoney' ID 2 connected.
Disconnecting player 'arbamoney' at ID 2, sent quit packet with reason 1.
Player 'arbamoney' ID 2 disconnected.
Disconnecting player 'heizter' at ID 0, sent quit packet with reason 1.
Player 'heizter' ID 0 disconnected.
Player 'Dusanbajev' ID 0 connected.
Player 'Dusanbajev' ID 0 disconnected (kicked).
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Player 'KURVAANYAD' ID 0 connected.
Player 'KURVAANYAD' ID 0 disconnected (kicked).
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Player 'DAGADT_GECI' ID 0 connected.
Player 'DAGADT_GECI' ID 0 disconnected (kicked).
Player 'papaszemes' ID 0 connected.
Player 'papaszemes' ID 0 disconnected (kicked).
Player 'Fogyjal_le' ID 0 connected.
Player 'Fogyjal_le' ID 0 disconnected (kicked).
Player 'VRLice' ID 0 connected.
Player 'VRLice' ID 0 disconnected (kicked).
Disconnecting player 'Szondikapitany' at ID 1, sent quit packet with reason 1.
Player 'Szondikapitany' ID 1 disconnected.
Player 'MEGDOGLESZ' ID 0 connected.
Disconnecting player 'MEGDOGLESZ' at ID 0, sent quit packet with reason 1.
Player 'MEGDOGLESZ' ID 0 disconnected.
Player 'Szondikapitany' ID 0 connected.
[/noae][/noae][/noae][/noae][/noae]




My solution for now is a windows firewall rule. Not elegant but working
Try changing the CheckBan function to this:
[noae][noae][noae]function CheckBan(plr)
{
local q = QuerySQL(Bans, format("SELECT * FROM Bans WHERE UniqueID = '%s'", plr.UniqueID));
if (q) {
MessagePlayer("[#95fcff]INFO > [#E0E0E0]You're banned from the server. Reason:"+GetSQLColumnData(q, 1), plr);
plr.Kick(); }else return 0;
}
[/noae][/noae]

P.S: Remove the if statement from onPlayerJoin function. Also that's how a common ban system works. It checks the banned player's UID inputed into the database and if the UID exists, it kicks the player.

shaddam17

I tried it yesterday, but no change. The banned person can reconnect

Player 'TakeshiKovacs' ID 0 disconnected (kicked).
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Player 'TakeshiKovacs' ID 0 connected.

AN ERROR HAS OCCURED [the index 'UniqueID' does not exist]

CALLSTACK
*FUNCTION [GetInfo()] scripts/main.nut line [398]
*FUNCTION [onPlayerJoin()] scripts/function.nut line [150]

LOCALS
[p] USERPOINTER
[q] USERPOINTER
[player] INSTANCE
[this] TABLE
[country] "Hungary"
[player] INSTANCE
[this] TABLE



habi

You may not pass 'player' to functions.

GetInfo(player) change to GetInfo(player. ID)

because by the time it reaches function,  the player might disconnected and error happens

SHy^

#13
Quote from: shaddam17 on Dec 23, 2020, 08:12 AMI tried it yesterday, but no change. The banned person can reconnect

Player 'TakeshiKovacs' ID 0 disconnected (kicked).
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Kicking player ID 0, no record of such connection ID exists.
Player 'TakeshiKovacs' ID 0 connected.

AN ERROR HAS OCCURED [the index 'UniqueID' does not exist]

CALLSTACK
*FUNCTION [GetInfo()] scripts/main.nut line [398]
*FUNCTION [onPlayerJoin()] scripts/function.nut line [150]

LOCALS
[p] USERPOINTER
[q] USERPOINTER
[player] INSTANCE
[this] TABLE
[country] "Hungary"
[player] INSTANCE
[this] TABLE



If the banned player reconnects, does the server kick him because of being banned?

Also try what @habi said. Pass the player's ID to the function and then create a local var with FindPlayer(player.ID) and then continue with an if statement.

Xmair

#14
Quote from: habi on Dec 23, 2020, 08:51 AMYou may not pass 'player' to functions.

GetInfo(player) change to GetInfo(player. ID)

because by the time it reaches function,  the player might disconnected and error happens
As far as I know, the server is single threaded and it's not going to release the player's information until your onPlayerPart event is completed.

:edit: I just took a look at the script, there's no "UniqueID" member in the PlayerClass, you need to add it manually. Though there seem to be a ton of other issues in the script and I personally wouldn't recommend using this :/

Credits to Boystang!

VU Full Member | VCDC 6 Coordinator & Scripter | EG A/D Contributor | Developer of VCCNR | Developer of KTB | Ex-Scripter of EAD