SA-MP Forums Archive
"Groups" to "Factions" - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: "Groups" to "Factions" (/showthread.php?tid=205035)



"Groups" to "Factions" - Deal-or-die - 31.12.2010

Im using a script that my mate gave me before going on holiday and i just went through the script changing all of the "Group"s to "Faction"s and all the "group"s to "faction"s but when i compile it gives me an error
Код:
(10287) : warning 219: local variable "Faction" shadows a variable at a preceding level
and the line "10287" is
Код:
public LiteralFactionMessage(Faction, colour, string[])
so i changed it to
Код:
public LiteralFactionMessage(faction, colour, string[])
but then i got this Error:
Код:
(10287) : error 025: function heading differs from prototype
any help is Hugely appreciated Thanks


Re: "Groups" to "Factions" - Flyfishes - 31.12.2010

public LiteralFactionMessage(faction, colour, string[]); is correct.
You have to forward it with the right names too. So forward it like:
forward LiteralFactionMessage(faction, colour, string[]);


Re: "Groups" to "Factions" - Deal-or-die - 31.12.2010

Ahh, ok, but then why am i getting this error?
Код:
(10287) : error 025: function heading differs from prototype



Re: "Groups" to "Factions" - MadeMan - 31.12.2010

Did you change the forward also?


Re: "Groups" to "Factions" - Deal-or-die - 31.12.2010

no..... lol my bad ill try it


Re: "Groups" to "Factions" - Deal-or-die - 31.12.2010

ok, well i had a look and i can't seem to find the forward what should it look like and where abouts should i find it?
:/


Re: "Groups" to "Factions" - yanir3 - 31.12.2010

public LiteralFactionMessage(Faction, colour, string[])


Re: "Groups" to "Factions" - Deal-or-die - 31.12.2010

then how do i fix this?
Код:
(10287) : warning 219: local variable "Faction" shadows a variable at a preceding level