SA-MP Forums

Go Back   SA-MP Forums > Search Forums

Showing results 1 to 25 of 500
Search took 0.03 seconds.
Search: Posts Made By: LarzI
Forum: Filterscripts 09/06/2016, 09:48 PM
Replies: 18
[FilterScript] Simple Cellphones
Views: 10,935
Posted By LarzI
Re: Simple Cellphones

It's old, but thanks anyway dude :)
Forum: Scripting Help 11/05/2013, 01:07 PM
Replies: 8
Views: 774
Posted By LarzI
Re: zcmd, strcmp and dcmd.

YCMD is proven to be faster than ZCMD after a certain amount of commands in your script. If you're making a big script, you should definitely use YCMD.
Forum: Scripting Help 08/05/2013, 02:49 PM
Replies: 4
Views: 703
Posted By LarzI
Re: KillTimer not work

Declaration is when you use new, static, stock infront of the variable names to add it to your script
Assignment is when you use symbols like =, +=, -=.
Forum: Tutorials 05/05/2013, 02:20 PM
Replies: 51
Views: 31,493
Posted By LarzI
Re: An in-depth look at binary and binary operators.

I used "discovered" very loosely, as I couldn't seem to find the word I was looking for (e.g. "documented"), but yes that's obviously true.
Forum: Tutorials 05/05/2013, 12:55 PM
Replies: 51
Views: 31,493
Posted By LarzI
Re: An in-depth look at binary and binary operators.

The most common example is KeyStates: http://wiki.sa-mp.com/wiki/OnPlayerKeyStateChange
Another example is Bit-Flags - a method discovered by Slice to use one single variable to hold up to 32...
Forum: Scripting Help 26/04/2013, 10:05 AM
Replies: 600
Views: 77,225
Posted By LarzI
Re: Script Request Thread #6

Well let's say there's 3 hospitals, and their coordinates are: 10, 10, 10 | 20, 20, 20 | -15, -15, -15
You'd have to save those coordinates to for example an array:

new
...
Forum: Scripting Help 26/04/2013, 07:22 AM
Replies: 600
Views: 77,225
Posted By LarzI
Re: Script Request Thread #6

Save the hospitals' positions into variables, get the player's position and subtract the X and Y coordinates to get the distance (You can use e.g. Pytagoras). Do this for every hospital coordinates...
Forum: Scripting Help 19/04/2013, 10:59 AM
Replies: 7
Views: 1,303
Posted By LarzI
Re: Range ban Using GEO IP

Why do you want to use Geo IP for that? You can just range ban by using asterisks as wild-cards!

SendRconCommand( "banip 255.255.*.*" );
Forum: Scripting Help 19/04/2013, 08:57 AM
Replies: 8
Views: 714
Posted By LarzI
Re: Register Spawning bug

I'm currently at school (food-break) and I don't have access to skype here because of Internet-block (I'm browsing on my phone, but I can probably take a look at it when I get home (in about an hour...
Forum: Scripting Help 19/04/2013, 08:54 AM
Replies: 8
Views: 714
Posted By LarzI
Re: Register Spawning bug

Did you try checking under OnPlayerSpawn? Is it still 1? It shouldn't be as the player gets kicked. Conclusion: You reset the value somewhere between THREAD_REGISTER_SPAWN and OnPlayerSpawn.
Forum: Scripting Help 19/04/2013, 08:50 AM
Replies: 6
Views: 634
Posted By LarzI
Re: Y_Commands | Explanation Please.

The tutorial topic DOES explain it in easy words.



Nothing.

The help parameter is something you can provide to have a command-description system (or something similar).
****** provides an...
Forum: Scripting Help 19/04/2013, 08:36 AM
Replies: 8
Views: 714
Posted By LarzI
Re: Register Spawning bug

I repeat: Debug your spawn-thread, or possibly all related code. http://wiki.sa-mp.com/wiki/Debugging
Forum: Scripting Help 19/04/2013, 06:41 AM
Replies: 8
Views: 714
Posted By LarzI
Re: Register Spawning bug

Debug your spawn-thread. Somehow pStatus isn't being assigned to the value 1.
Forum: Scripting Help 19/04/2013, 06:34 AM
Replies: 4
Views: 1,312
Posted By LarzI
Re: YSI\y_timers

Don't be ignorant. You may have done something faulty in the code causing this to happen.
Forum: Scripting Help 18/04/2013, 04:13 PM
Replies: 9
Views: 716
Posted By LarzI
Re: Sellvehicle command [You can't sell to yourself]

Compare playerid with giveplayerid and disallow the command if it returns true (matching IDs)

Example:
if( giveplayerid == playerid )
return SendClientMessage( playerid, 0xFF0000AA, "[ERROR]...
Forum: Scripting Help 18/04/2013, 01:31 PM
Replies: 12
Views: 1,058
Posted By LarzI
Forum: Scripting Help 15/04/2013, 09:16 PM
Replies: 22
Views: 1,496
Posted By LarzI
Re: Score left for next rank?

Care to show all the relevant code? There's surely a simply error somewhere (not a compiler error - but faulty code) that should be relatively easy to fix.
Forum: Scripting Help 15/04/2013, 08:59 PM
Replies: 22
Views: 1,496
Posted By LarzI
Re: Score left for next rank?

Then remove the -1 from the RankScore cell and add +1 (I failed hard on this part, sorry)
Forum: Scripting Help 15/04/2013, 08:35 PM
Replies: 22
Views: 1,496
Posted By LarzI
Re: Score left for next rank?

Then I'm not sure :/ If no one has answered by tomorrow, I'll hti you back - I'm really tired
Forum: Scripting Help 15/04/2013, 07:30 PM
Replies: 22
Views: 1,496
Posted By LarzI
Re: Score left for next rank?

I'm not entirely sure, although I noticed a mistake on my part:

Rank 1 = Cell 0 of RankScore, so you have to subtract pInfo[i][Rank] by 1:

new iNeededScore = g_RankScores[pInfo[i][Rank]-1] -...
Forum: Scripting Help 15/04/2013, 06:46 PM
Replies: 22
Views: 1,496
Posted By LarzI
Re: Score left for next rank?

They're called functions - "stock" is just the name of an attribute.



This is entirely possible by subtracting the player's score from the score needed to achieve next rank. To do this just...
Forum: Scripting Help 15/04/2013, 02:46 PM
Replies: 5
Views: 1,103
Posted By LarzI
Re: Function ProxDetector

That's pretty much what it does, yes. It loops trough all the players, and sends them a given string if they are in a given range. The color of the message depends on the current position of the...
Forum: Scripting Help 15/04/2013, 02:30 PM
Replies: 5
Views: 1,103
Posted By LarzI
Re: Function ProxDetector

If you don't know, why do you want to use it?
Forum: Scripting Help 14/04/2013, 03:53 PM
Replies: 15
Views: 2,053
Posted By LarzI
Re: How to delete a line in a .txt file?

Let us see your fdeleteline function
Forum: Scripting Help 14/04/2013, 03:46 PM
Replies: 15
Views: 2,053
Posted By LarzI
Re: How to delete a line in a .txt file?

fdeleteline automaticly opens, reads, deletes and closes. You'll have to open the file again to write to it.

Edit: IIRC.
Showing results 1 to 25 of 500

 

All times are GMT. The time now is 06:34 AM.


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