Tutorial -> Convert 0.2x script to 0.3a
#21

Quote:
Originally Posted by sexybeast
Im still getting this "m 0 <text>" thing when i use /pm. Does anyone know what my problem is?
Yup, found the problem. I've changed that portion of the script so that this line:
pawn Код:
new begintext = strfind(cmdtext[4]," ")+1;
Is now
pawn Код:
new begintext = strfind(cmdtext[4]," ")+1+4;
Reply
#22

Thanks, now works.
Reply
#23

thanks nice tutorial, but when i convert my 0.2x script to 0.3a, my spawnpoints seem to change and i really cant solve this cause players should spawn at their houses(btw i use penls script)
anyone can help?
Reply
#24

Thanks
I've already converted it.
Reply
#25

SA-MP Dedicated Server
----------------------
v0.3a R3, ©2005-2009 SA-MP Team

[19:30:29] filterscripts = "" (string)
[19:30:29]
[19:30:29] Server Plugins
[19:30:29] --------------
[19:30:29] Loaded 0 plugins.

[19:30:29]
[19:30:29] Filter Scripts
[19:30:29] ---------------
[19:30:29] Loaded 0 filter scripts.

[19:30:29] Pickups max = 100, Pickup using = 129
[19:30:29]
[19:30:29]
[19:30:29] Gangsta lifecity= -
[19:30:29] _____________________
[19:30:29] GLC - RP
[19:30:29]
[19:30:29] Number of vehicle models: 59
[19:30:33] --- Server Shutting Down.


Once I turn I can not go on my server? help!


Reply
#26

Quote:

[19:30:29] Pickups max = 100, Pickup using = 129

Looks like you're using too many pickups in that script. It could be many things though if that's not the problem, need to see the script(s) and setup...
Reply
#27

I would not touch with any filterscript, he is a godfather changed, I think it's to the cars that version needs to change the codex of the cars? I put addstaticvehicleex
Reply
#28

C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\hcrp.pwn(813 : error 004: function "OnPlayerPrivmsg" is not implemented
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\hcrp.pwn(8144) : error 017: undefined symbol "text"
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\hcrp.pwn(8146) : error 017: undefined symbol "text"

HELP!
Reply
#29

Quote:
Originally Posted by mrdja1
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\hcrp.pwn(813 : error 004: function "OnPlayerPrivmsg" is not implemented
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\hcrp.pwn(8144) : error 017: undefined symbol "text"
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\hcrp.pwn(8146) : error 017: undefined symbol "text"

HELP!
You need create the forward "OnPlayerPrivmsg" and define the text; new text[128];
Reply
#30

Thanks, i got the Text squared away but i still have the (error 004: function "OnPlayerPrivmsg" is not implemented)
The forward i have is (forward OnPlayerPrivmsg(playerid,receiverid,text[])
I tried compiling with (forward OnPlayerPrivmsg() Same error.
Reply
#31

gamemodes\GGL.pwn(33 : error 025: function heading differs from prototype

forward OnPlayerPrivmsg(playerid,receiverid,text[]);


gamemodes\GGL.pwn(1068 : warning 219: local variable "playermoney" shadows a variable at a preceding level
new playermoney;

gamemodes\GGL.pwn(35179) : error 025: function heading differs from prototype


gamemodes\GGL.pwn(36140) : error 021: symbol already defined: "NameTimer"
public NameTimer()
{


Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


3 Errors.

Reply
#32

Quote:
Originally Posted by mrdja1
Thanks, i got the Text squared away but i still have the (error 004: function "OnPlayerPrivmsg" is not implemented)
The forward i have is (forward OnPlayerPrivmsg(playerid,receiverid,text[])
I tried compiling with (forward OnPlayerPrivmsg() Same error.
its removed since 0.3
Reply
#33

I receive this error when i compile !
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29171) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : error 017: undefined symbol "Mute"
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : warning 215: expression has no effect
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : error 001: expected token: ";", but found "]"
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : error 029: invalid expression, assumed zero
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : fatal error 107: too many error messages on one line

In pawno i have this : public OnPlayerPrivmsg(playerid, receiverid, text[])
{
if(Mute[playerid] == 1) return 0;
PlayerRespond [receiverid] = playerid;

new pname[MAX_PLAYER_NAME];
new rname[MAX_PLAYER_NAME];
new tmpstring[256];
GetPlayerName(receiverid,rname,sizeof(rname));
GetPlayerName(playerid,pname,sizeof(pname));
format(tmpstring,sizeof(tmpstring),"to %s(%d): %s",rname,receiverid,text);
SendClientMessage(playerid,0xFFCC22FF,tmpstring);
format(tmpstring,sizeof(tmpstring),"from %s(%d): %s",pname,playerid,text);
SendClientMessage(receiverid,0xFFFF22FF,tmpstring) ;
//Above return 1
return 1;
}
Reply
#34

Can someone help me please ?

I receive this error when i compile !
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29171) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : error 017: undefined symbol "Mute"
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : warning 215: expression has no effect
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : error 001: expected token: ";", but found "]"
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : error 029: invalid expression, assumed zero
E:\Program Files\SAMP Server\gamemodes\gf_ro2.4.5.pwn(29173) : fatal error 107: too many error messages on one line

In pawno i have this : public OnPlayerPrivmsg(playerid, receiverid, text[])
{
if(Mute[playerid] == 1) return 0;
PlayerRespond [receiverid] = playerid;

new pname[MAX_PLAYER_NAME];
new rname[MAX_PLAYER_NAME];
new tmpstring[256];
GetPlayerName(receiverid,rname,sizeof(rname));
GetPlayerName(playerid,pname,sizeof(pname));
format(tmpstring,sizeof(tmpstring),"to %s(%d): %s",rname,receiverid,text);
SendClientMessage(playerid,0xFFCC22FF,tmpstring);
format(tmpstring,sizeof(tmpstring),"from %s(%d): %s",pname,playerid,text);
SendClientMessage(receiverid,0xFFFF22FF,tmpstring) ;
//Above return 1
return 1;
}
Reply
#35

Can any script be converted from 0.2x to 0.3a? Like, are there any scripts that can not be turned?
Reply
#36

Quote:
Originally Posted by maam10
Can any script be converted from 0.2x to 0.3a? Like, are there any scripts that can not be turned?
Generally yes, the only few that cannot be are specific to functions that were removed like DisableWeapon and SetVehiclePlate. However, some script srequire more work to be converted, like those that lock vehicles.
Reply
#37

Quote:
Originally Posted by Joe Staff
Quote:
Originally Posted by maam10
Can any script be converted from 0.2x to 0.3a? Like, are there any scripts that can not be turned?
Generally yes, the only few that cannot be are specific to functions that were removed like DisableWeapon and SetVehiclePlate. However, some script srequire more work to be converted, like those that lock vehicles.
So in other words.. Almost no RP script can be converted using this tutorial?

Sorry, i'm new in scripting, and trying to learn.. :P
Reply
#38

All Scripts can be, it's just that SetDisabledWeapons and SetVehiclePlate don't work, so they'll have to be removed. And lockable vehicles are still possible, it just requires one more extra step.
Reply
#39

Please help me!!The penls.pwn file is not in the gamemodes folder.What should I do?
Reply
#40

Quote:
Originally Posted by Vaggos_Ryder
Please help me!!The penls.pwn file is not in the gamemodes folder.What should I do?
Download it?


Код:
error 025: function heading differs from prototype
error 017: undefined symbol "receiverid"
error 017: undefined symbol "receiverid"
error 017: undefined symbol "receiverid"
How to fix them?
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)