SA-MP Forums

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

Reply
 
Thread Tools Display Modes
Old 09/11/2011, 02:27 AM   #11
Norn
High-roller
 
Norn's Avatar
 
Join Date: Jul 2008
Location: Northern Ireland
Posts: 2,265
Reputation: 206
Default Re: Creating /s and /l commands

pawn Code:
GetPlayerPos(playerid,PPosition[playerid][XPos],PPosition[playerid][YPos],PPosition[playerid][ZPos]);
GetPlayerFacingAngle(player,PPosition[playerid][PAngle]);

Magic
__________________
Pursuing other endeavours.

Skype: datinvictusguy
Norn is offline   Reply With Quote
Old 13/11/2011, 12:27 PM   #12
Kostas'
High-roller
 
Kostas''s Avatar
 
Join Date: Sep 2011
Location: Athens, Greece
Posts: 1,063
Reputation: 101
Default Re: Creating /s and /l commands

There is a typing mistake
pawn Code:
GetPlayerFacingAngle(player,angle);//Storing the player's angle to "angle".
You forgot the "id" => playerid
__________________
Knowledge:
  • HTML
  • Pascal
  • Visual Basic
  • Algorithm
    • Pseudocode
Kostas' is offline   Reply With Quote
Old 13/11/2011, 01:01 PM   #13
FireCat
High-roller
 
FireCat's Avatar
 
Join Date: Jul 2010
Posts: 2,322
Reputation: 609
Default Re: Creating /s and /l commands

Quote:
Originally Posted by Kostas' View Post
There is a typing mistake
pawn Code:
GetPlayerFacingAngle(player,angle);//Storing the player's angle to "angle".
You forgot the "id" => playerid
Lol thanks :b
FireCat is offline   Reply With Quote
Old 13/11/2011, 01:25 PM   #14
HyperZ
High-roller
 
HyperZ's Avatar
 
Join Date: Aug 2009
Location: Islamabad, Pakistan
Posts: 1,340
Reputation: 66
Default Re: Creating /s and /l commands

Nice Tutorial .
__________________
HyperZ is offline   Reply With Quote
Old 20/01/2014, 10:39 PM   #15
byzu210
Little Clucker
 
byzu210's Avatar
 
Join Date: May 2013
Location: United Kingdom
Posts: 9
Reputation: 0
Post Re: Creating /s and /l commands

Hey man when i was doing this, it gave me this little error if you can help me please and if you have skype add me
Skype: Byzu210

and here is the problem,
": error 017: undefined symbol "PPosition"
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : warning 215: expression has no effect
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : error 001: expected token: ";", but found "]"
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : error 029: invalid expression, assumed zero
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : fatal error 107: too many error messages on one line"
If you can help me about this, Thanks
__________________
byzu210 is offline   Reply With Quote
Old 20/01/2014, 10:54 PM   #16
Hansrutger
Gangsta
 
Hansrutger's Avatar
 
Join Date: May 2011
Location: Sweden
Posts: 761
Reputation: 161
Default Re: Creating /s and /l commands

Quote:
Originally Posted by byzu210 View Post
Hey man when i was doing this, it gave me this little error if you can help me please and if you have skype add me
Skype: Byzu210

and here is the problem,
": error 017: undefined symbol "PPosition"
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : warning 215: expression has no effect
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : error 001: expected token: ";", but found "]"
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : error 029: invalid expression, assumed zero
C:\Users\ConstantinNarcis\Desktop\Drift-United GTA United\gamemodes\Du.pwn(101) : fatal error 107: too many error messages on one line"
If you can help me about this, Thanks
Above in your script, add this:
Code:
new PPosition[MAX_PLAYERS][PlayerPosition];
Annnnnnddd you missed out a ; after an array on line 101 lol...
__________________


Hansrutger is offline   Reply With Quote
Old 20/01/2014, 11:05 PM   #17
byzu210
Little Clucker
 
byzu210's Avatar
 
Join Date: May 2013
Location: United Kingdom
Posts: 9
Reputation: 0
Default Re: Creating /s and /l commands

Man i have this on Top "new PPosition[MAX_PLAYERS][PlayerPosition]; " of my script but i;m still getting the same Error !!!!

Any more help ?
byzu210 is offline   Reply With Quote
Old 01/05/2014, 05:39 AM   #18
satafinix
Huge Clucker
 
satafinix's Avatar
 
Join Date: Apr 2013
Location: Marruecos
Posts: 300
Reputation: 15
Default Re: Creating /s and /l commands

Good Job
__________________
SA-MP: 5.231.53.212:7777
TS3: TS3.swx-stunting.ga
satafinix is offline   Reply With Quote
Reply

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
[Tutorial] Creating commands with y_commands and sscanf SmiT Tutorials 18 06/10/2012 03:44 PM
Help for creating a VIP commands ServerScripter Help Archive 6 04/07/2011 09:01 AM
[HELP]Creating commands that use '!' instead of '/' PCheriyan007 Help Archive 9 01/04/2011 08:15 PM
Creating RCON commands Mike Garber Help Archive 8 17/12/2009 12:51 PM
Commands creating random crashes.. _Vortex Help Archive 0 08/09/2009 02:22 AM


All times are GMT. The time now is 10:27 PM.


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