SA-MP Forums

Go Back   SA-MP Forums > Search Forums

Showing results 1 to 25 of 133
Search took 0.01 seconds.
Search: Posts Made By: Markski
Forum: Scripting Help 02/08/2020, 03:09 AM
Replies: 1
Views: 104
Posted By Markski
Re: Malfunctioning .cs script

This forum is for assistance with server-side SA-MP scripting, not Cleo scripting.

You'll find assistance with Cleo scripting at CLEO/Sanny Builder's forum...
Forum: Server Support 01/08/2020, 11:38 PM
Replies: 2
Views: 172
Posted By Markski
Re: SAMP server for ARM

USUALLY compiling to another platform is as simple as letting the compiler know the target platform. But not always. Impossible to know without knowing what samp-server's code looks like, which I do...
Forum: Scripting Help 30/07/2020, 10:12 PM
Replies: 12
Views: 255
Posted By Markski
Re: Error

Remove .dll. File extensions for plugins in the SA-MP server config are only needed on Linux, not on windows.

plugins mysql sscanf
Forum: Scripting Help 29/07/2020, 10:44 PM
Replies: 2
Views: 166
Posted By Markski
Re: Arrays problem

log_txd_text[5] = log_txd_text[4];
log_txd_text[4] = log_txd_text[3];
log_txd_text[3] = log_txd_text[2];
log_txd_text[2] = log_txd_text[1];
log_txd_text[1] = log_txd_text[0];


This is likely...
Forum: Scripting Help 29/07/2020, 10:31 PM
Replies: 8
Views: 203
Posted By Markski
Re: IG Damage log

The reply above is correct, but keep in mind that OnPlayerTakeDamage can easily be spoofed by the alleged victim's client. You probably want to make range and virtual world checks for these kinds of...
Forum: Scripting Help 29/07/2020, 06:24 PM
Replies: 12
Views: 255
Posted By Markski
Re: Error

We need a lot more detail than this. What isn't being found?
Forum: Scripting Help 23/07/2020, 12:26 AM
Replies: 10
Views: 236
Posted By Markski
Re: SQL 41-4 - Unknown column 'X' in 'field list'

"cache_get_value_name_int" and any other function that requires accesing a SQL cache will only inside the callback function specified for that query.

My suggestion is that you store that data in a...
Forum: Scripting Help 22/07/2020, 11:23 PM
Replies: 10
Views: 236
Posted By Markski
Re: SQL 41-4 - Unknown column 'X' in 'field list'

You must add ' symbols around strings in a SQL query.


mysql_format(g_SQL, query, sizeof query, "UPDATE `factions` SET `name` = '%s' WHERE `id` = %d", inputtext, facid);


` is used to...
Forum: Scripting Help 22/07/2020, 11:20 PM
Replies: 5
Views: 213
Posted By Markski
Re: how to transform an Hex color to RBGA color

strcat() is meant to receive two strings. You're feeding COLOR_* macros to it, which I assume are colour codes (integers)

As for the question in the title, I'd honestly suggest you don't bother...
Forum: Scripting Help 21/07/2020, 07:32 PM
Replies: 4
Views: 146
Posted By Markski
Re: Command Help

Essentially what the message above says. But aside from other variables, also be aware that repeating names between variables, functions and enumerators at preceeding levels might give this error,...
Forum: Scripting Help 21/07/2020, 05:55 PM
Replies: 4
Views: 146
Posted By Markski
Re: Command Help

You don't seem to be returning 0 in any condition, which is what would cause most command engines to send an "invalid command" message.

Make sure the code isn't running into any runtime errors...
Forum: Scripting Help 21/07/2020, 04:41 PM
Replies: 2
Views: 201
Posted By Markski
Re: ram usage HIGH increase

I reckon also make sure you're not spawning a high amount of objects per player then forgetting to despawn them, and make sure it's not your MySQL server overusing ram when caching through tables.
Forum: Scripting Help 28/04/2020, 01:24 PM
Replies: 10
Views: 265
Posted By Markski
Re: which is the maximum length of a string?

Just do one query per player. I'd suggest you do it across several multiple formats though, for the sake of your mental sanity.



In order to know if something changed or not you'd probably need...
Forum: Scripting Help 28/04/2020, 11:53 AM
Replies: 10
Views: 265
Posted By Markski
Re: which is the maximum length of a string?

Having a huge query to save account flags in a single table is fine. It's not ideal, but it's *fine*. Long as you know what you're doing the worst thing that'll happen is it just being annoying to...
Forum: Scripting Help 28/04/2020, 11:45 AM
Replies: 2
Views: 96
Posted By Markski
Re: Connecting two enums together

The only way to effectivelly do this would be to use apID as the index.

Other way would be to set apID to the id on each array at the same time, and letting each enum have a cache variable to hold...
Forum: Scripting Help 28/04/2020, 11:42 AM
Replies: 1
Views: 74
Posted By Markski
Re: warning 215: expression has no effect

All of the lines on the error log are super far away from each other so the snippet you provided won't suffice. We also have no way to know which of those lines is contained in the snippet you sent....
Forum: Scripting Help 28/04/2020, 11:34 AM
Replies: 2
Views: 113
Posted By Markski
Re: Issue with DCC_OnChannelMessage (outdated callback, perhaps?)

There's no easier way since the last DCC update. It shouldn't be that hard anyways, you'll just need to fetch those two things at the top of the callback. And of course, DCC_GetMessageContent for the...
Forum: Scripting Help 14/04/2020, 11:36 AM
Replies: 4
Views: 136
Posted By Markski
Re: Time until NPC reach a point

What Runn3R said should work. Alternatively, you should take your measurement for a single cycle, and reset it everytime the bus stops in the starting place, with a vehicle checkpoint as well.
Forum: Scripting Help 05/03/2020, 11:28 PM
Replies: 4
Views: 180
Posted By Markski
Forum: Includes 11/02/2020, 10:11 PM
Replies: 6
Views: 3,092
Posted By Markski
Re: 3D Speedometer v0.2

y_hooks is optional, hence the compiler checks on _INC_y_hooks, so having that array there is necesary one way or the other.

Also, 0.3:

- Added Spanish option
- Added option to disable vehicle...
Forum: Includes 10/02/2020, 06:23 PM
Replies: 6
Views: 3,092
Posted By Markski
3D Speedometer v0.3

An easy-to-implement 3D Speedometer.

- Include with y_hooks and it will work inmediatly.
- If you don't have y_hooks then making it work is as simple as pasting a few lines of code in 4...
Forum: Scripting Help 03/02/2020, 03:24 AM
Replies: 3
Views: 168
Posted By Markski
Re: Shorten this

What's wrong with that? IMO it's the best approach for this solution.

To answer your question though, there's this:

stock bool:FALSE = false;
new scmExStr[144];
#define...
Forum: Scripting Help 02/02/2020, 02:12 PM
Replies: 5
Views: 321
Posted By Markski
Re: Server optimization

Memory sizes are meaningless for speed, lowering memory usage won't improve anything since no script will ever use more than 300mb of ram anyways.

What should concern you is performance profilings...
Forum: Scripting Help 31/01/2020, 12:41 PM
Replies: 5
Views: 302
Posted By Markski
Re: easyDialog.inc exceed heap size

If you mean the amount of heap that your script will use in the worst case scenario, the compiler says it here:



Again, this is calculated based on how much function calling depth your script...
Forum: Scripting Help 30/01/2020, 09:07 PM
Replies: 5
Views: 302
Posted By Markski
Re: easyDialog.inc exceed heap size

Heap/stack size max. usage estimations are based, mostly, on how much depth of function calls your script might fall into. Provided there is no recursion, in which case it'd theoretically be...
Showing results 1 to 25 of 133

 

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


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