SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Thread Tools Display Modes
Old 02/12/2011, 10:22 AM   #1
Night Dreamer
Big Clucker
Night Dreamer's Avatar
Join Date: Nov 2011
Posts: 39
Reputation: 0
Default function body without function header.

I have:
#define CBP:%0(%1, {Float, _}:...) forward %0(%1, {Float, _}:...); public %0(%1, {Float, _}:...)

probleme is " error 055: start of function body without function header "

public Is:
CBP:AccountDataLoad(playerid, tag[], name[], value[])

who can I make it work?

PS: I fix probleme add this #define CBP:%0({Float, _}:...) forward %0({Float, _}:...); public %0({Float, _}:...)

But I have warning " warning 208: function with tag result used before definition, forcing reparse "
Night Dreamer is offline   Reply With Quote
Old 02/12/2011, 10:28 AM   #2
Mauzen's Avatar
Join Date: Jun 2007
Location: Western Germany
Posts: 4,778
Reputation: 1313
Default Re: function body without function header.

You cant use this: {Float, _}:... in a define, as this pattern cant be detected by the precompiler. But you can simply leave it out, the %1 will not only include one parameter, but everything between the ():

#define CBP:%0(%1) forward %0(%1); public %0(%1)
Mauzen is offline   Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help with function. CoaPsyFactor Help Archive 4 03/06/2011 08:43 AM
Function Unknown123 Help Archive 7 09/05/2011 05:47 PM
Function just stops other function Blay09 Help Archive 2 01/01/2011 01:26 PM
Function Help VictorMartinez Help Archive 6 21/07/2010 02:36 AM
function not working after another function [HLF]Southclaw Help Archive 5 03/05/2010 05:45 PM

All times are GMT. The time now is 08:23 AM.

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