SA-MP Forums

Go Back   SA-MP Forums > Search Forums

Showing results 1 to 25 of 210
Search took 0.01 seconds.
Search: Posts Made By: Lucases
Forum: Scripting Help 11/07/2018, 02:11 PM
Replies: 25
AFK
Views: 750
Posted By Lucases
Re: AFK

That's not accurate.
You should use the position but also OnPlayerUpdate to check if a player is AFK, simply because if the player pressed the ESC button or used ALT+TAB OnPlayerUpdate won't be...
Forum: Scripting Help 17/06/2018, 10:43 PM
Replies: 6
Views: 483
Posted By Lucases
Re: Unknown Command

Why are you using mysql_free_result inside the if statement and outside it?
Won't it try to free the result twice?
Forum: Scripting Help 17/06/2018, 10:30 PM
Replies: 5
Views: 347
Posted By Lucases
Re: help me guys

What? If the timer starts with the player id 2 as parameter and while it's running the player with ID 2 logs out and another one logs in he will get killed.

Simply add this:

public...
Forum: Scripting Help 27/02/2018, 09:11 PM
Replies: 18
Views: 803
Posted By Lucases
Re: problem with cmd /top with mysql

Try to send the query directly from the database
If it gives you some errors you will be able to fix the issue
Forum: Scripting Help 27/02/2018, 09:02 PM
Replies: 7
Views: 1,844
Posted By Lucases
Exclamation Re: Problem with TogglePlayerControllable

Because they can go around with endless health while their afk variable is set on true?
Freezing them is the best option.
Forum: Scripting Help 25/02/2018, 06:57 AM
Replies: 16
Views: 736
Posted By Lucases
Re: Command spams

Why don't you just save the timestamp and check if a number of seconds didn't pass yet.
Forum: Scripting Help 07/02/2018, 08:29 PM
Replies: 5
Views: 335
Posted By Lucases
Re: How to make an animated TD?

You can use a repeating timer to change the AA value, so it will have a fade effect.
Forum: Scripting Help 18/01/2018, 08:01 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

First you don't show the dialog again after the player types a wrong password, second you put 2000 in the timer, it's a lot, make it 300.
Forum: Scripting Help 18/01/2018, 03:44 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

It's not LoginAttemps, delete that, it's LoginAttempts.

You need to create that variable at the top of your script, under color defines.etc.

You need to reset the variable under OnPlayerConnect...
Forum: Scripting Help 18/01/2018, 03:42 PM
Replies: 23
Views: 1,681
Posted By Lucases
Re: Encryption

Use SHA_256 instead
Forum: Scripting Help 17/01/2018, 05:09 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

Do you reset the variable under OnPlayerConnect?
Forum: Scripting Help 17/01/2018, 04:27 PM
Replies: 20
Views: 978
Posted By Lucases
Forum: Scripting Help 16/01/2018, 09:05 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

You have already defined KickPlayer

Replace KickPlayer in my code with something else, like AttemptsKick
Forum: Scripting Help 16/01/2018, 08:57 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

Sorry my bad

Change


new LoginAttemps[MAX_PLAYERS];


To
Forum: Scripting Help 16/01/2018, 08:54 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

Did you add the variable at the top of your script like I have said?

Also remember to add


LoginAttempts[playerid]=0;

Under OnPlayerConnect
Forum: Scripting Help 16/01/2018, 08:38 PM
Replies: 20
Views: 978
Posted By Lucases
Re: Help with login with 3 warnings.

At the top of your script


new LoginAttemps[MAX_PLAYERS];

forward public KickPlayer(playerid);
public KickPlayer(playerid) return Kick(playerid);
Forum: Scripting Help 16/01/2018, 08:29 PM
Replies: 8
Views: 473
Posted By Lucases
Re: /back command

SetSpawnInfo bust be used before SpawnPlayer or it will spawn you in random places
Forum: Scripting Help 13/01/2018, 09:51 PM
Replies: 5
Views: 359
Posted By Lucases
Re: tutorial stuck on stage 2

You don't set spawn Info before spawning
Forum: Scripting Help 13/01/2018, 09:45 PM
Replies: 9
Views: 512
Posted By Lucases
Re: Command

Basically you first check if they typed "money" or "wepon", then you check again the command params with "ui", which is always false, because there's "money" or "weapon after params
Forum: Scripting Help 12/01/2018, 09:08 PM
Replies: 1
Views: 306
Posted By Lucases
Re: Cant Create File.

Without code nothing can be done here
Forum: Scripting Help 12/01/2018, 08:59 PM
Replies: 3
Views: 361
Posted By Lucases
Re: double clock?

Use this function with 0 as second parameter

http://wiki.sa-mp.com/wiki/TogglePlayerClock
Forum: Scripting Help 12/01/2018, 08:56 PM
Replies: 14
Views: 879
Posted By Lucases
Forum: Scripting Help 12/01/2018, 08:08 PM
Replies: 4
Views: 461
Posted By Lucases
Re: CMD /oldcar(your last car) and i want /lastdriver(player's last car)

Infact the last should be update only when the player exites the vehicle, not when he enters.
Forum: Scripting Help 12/01/2018, 08:04 PM
Replies: 14
Views: 879
Posted By Lucases
Re: warning 208: function with tag result used before definition, forcing reparse

Forward it with the tag

Like



forward Float:function(params);
Forum: Scripting Help 12/01/2018, 04:16 PM
Replies: 4
Views: 461
Posted By Lucases
Re: CMD /oldcar(your last car) and i want /lastdriver(player's last car)

Inefficient code. You store only the id and don't check if it's connected. Also if that player logs out and someone else joins with the same ID you'll receive wrong informations.You shouuld store the...
Showing results 1 to 25 of 210

 

All times are GMT. The time now is 01:40 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.