• Welcome to Vice City Multiplayer.
 

[PAWN] Pickup function

Started by Frankie, March 26, 2010, 11:58:46 AM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Frankie

The syntax given in my script file (downloaded as GUPS 1.15) is this:

Quote
AddStaticPickup(id, type, Float:x, Float:y, Float:z, ammo, respawnseconds)

However, this does not correspond with the pawno default syntax. This means not only does it produce errors when compiling (nothing of grave concern) but it means the last 2 parts of the function do not work.

I can get around the ammo problem by placing loadsa pickups in the same place (messy but it works) but I cannot get around the respawn seconds problem.

It is essential to my script to have pickups that are either permanent or appear to be; ie respawning in a matter of milliseconds.

Is there any way for this to work? If not I suggest it is added to the next patch.

Boss

The correct syntax is AddStaticPickup(id, type, Float:x, Float:y, Float:z).

There is currently no way to either respawn pickups or set their ammo.

Frankie

Quote from: Boss on March 26, 2010, 12:18:45 PM
There is currently no way to either respawn pickups or set their ammo.
:-[

Is there any information about whether it will be in the next version/patch?

Also why is that syntax given if it doesn't work? I'm assuming it wasn't put there by Tamas or any of the other GUPS contributors.

The default pickup time is what like, 4 minutes? I could have sworn I saw a server around that had faster respawn time than that.


/edit One server I saw was Miami-Dade racing server. That is done on mIRC, does that mean it is possible with an MRC script, but not with a pawn one?

ramandu

a timer worked for me, sometimes forcing these things works

Frankie

How would I go about that? Is it a simple script?

Sorry I'm new to scripting, not very experienced with it.

Boss

Pawn and mrc servers are currently gradually different. While mrc has been there for a while, pawn has been implemented just recently, so it is currently in many ways inferior to mrc. And, since most of the servers are mrc (probably for that very reason), you have probably seen "quicker" pickups on one of them.

Speaking of Miami-Dade, it uses squirrel server, which functionality is different from both mrc and pawn ones, so don't be surprised to see anything there.

Frankie

One would wonder why the people in charge would introduce a new scripting base with less 'true' functionality than the previous one. You'll probably say something like it is a base that can be developed in the future to exceed the functionality of mIRC, well isn't that what beta tests are for? Or is R2 just one big beta test?

Also, not only to introduce this inferior base but then proclaim it to new users as the right/only method to use, seems questionable. A quote lifted from the official vcmp wiki, developed by yourself if I'm not wrong 'Boss':

QuoteScripting in VC-MP is done via the means of pawn scripting language. There are many editors [1] for it avaliable, but Pawno is a most common one.

Why release a new version and then digress from the already established functionality?

Providing one and only one scripting method on the 'official' wiki, when there are more useful ones out there, just seems ignorant.

Boss

Quote from: Frankie on March 26, 2010, 03:17:49 PM
Why release a new version and then digress from the already established functionality?
I suppose it was done in order for scripters to get aquainted with pawn (for those who had no experience with SA:MP's scripting). Also, while having "digressed" functionality (which can be seen only in few functions), pawn features more "integrated" scripting solution - you don't have to connect scripts to server, they can't suddenly "timeout" from etc.

Plus, it is safe to say that the upcoming release (which is, I repeat yet again, uses pawn) is absolutely superior to mrc.

Quote from: Frankie on March 26, 2010, 03:17:49 PM
Providing one and only one scripting method on the 'official' wiki, when there are more useful ones out there, just seems ignorant.
1) I don't think you know the basics of wikis. They are not "big readmes", written by devs/testers, they are free-to-edit databases to which anyone can contribute.
2) As a result of above, content greatly depends on contributors. I, as one of the biggest contributors, had only enough knowledge/will/time to fill in pawn information. You are free to add mrc/squirrel information if you feel it's missing.
3) There is an unofficial wiki, hosted by VRocker, which covers mrc and squirrel scripting. It can be found here -> http://liberty-unleashed.co.uk/VCWiki/Main_Page

Frankie

//off-topic Ok fair enough, I am presuming here that you are the person who wrote 'Scripting in VC-MP is done via the means of pawn scripting language.' As you are the person who set up the wiki, meaning you did the framework. Anyway this is a moot point, just nit-picking really.

It is nice to know there is also an 'un-official' wiki that documents things to a higher degree than the 'official' wiki, perhaps it would be in your interest to include a link to that wiki underneath your official one, so as to provide a fair alternative and means to learn mIRC scripting if we so choose.

//on-topic
So how would I go about setting a timer in pawn to 'force' the pickup into staying there/respawning quickly?

Boss

Quote from: Frankie on March 31, 2010, 04:12:37 PM
So how would I go about setting a timer in pawn to 'force' the pickup into staying there/respawning quickly?
Not currently possible, since AddStaticPickup can only create pickups in OnGameModeInit. But, once it is possible, you would use OnPickedUp for that.

Jancis_LV

Ammo works, but respawn seconds not, i tested that about week ago.
Latvian Vice City server
78.84.47.75:5192