Better idea than that difficult IsPlayerInArea
#1

Hey, can someone help me with removing those errors/warnings? I have a bad feeling I;m doint it wrong T.T
I have this code:
pawn Код:
public OnPlayerCommandText(playerid,cmdtext[])
{
  if(iamatdm == 0)
  {
  /jetpack, /healme;
  }
  else
  {
    SendClientMessage(playerid,0xFF0000FF,"You Cant Use Commands In Dm Area!!");
  }
  return 0;
}
And here are my errors:
Код:
C:\Users\Nel\Desktop\Mijn spullen\GTA Games\Server test gta\filterscripts\Test.pwn(41) : error 017: undefined symbol "iamatdm"
C:\Users\Nel\Desktop\Mijn spullen\GTA Games\Server test gta\filterscripts\Test.pwn(43) : error 029: invalid expression, assumed zero
C:\Users\Nel\Desktop\Mijn spullen\GTA Games\Server test gta\filterscripts\Test.pwn(43) : error 017: undefined symbol "jetpack"
C:\Users\Nel\Desktop\Mijn spullen\GTA Games\Server test gta\filterscripts\Test.pwn(43) : error 017: undefined symbol "healme"
C:\Users\Nel\Desktop\Mijn spullen\GTA Games\Server test gta\filterscripts\Test.pwn(43) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


5 Errors.
Just adding new didn't work. can someone help? Thanks.

EDIT: All the players that are in a DM area can't use these commands. (only outside)
Reply
#2

I just have to ROFL at this this is an EPIC FAIL

Use isplayerinarea



Quote:
On top
new iamatdm;
new jetpack;
new healme;

WHAT THE HELL USE THIS ITS THE SAME BUT I TOOK OUT /HEALME AND SUMET ELSE CAUS I DONT KNOW WHAT THE FUK IT WAS

Quote:

public OnPlayerCommandText(playerid,cmdtext[])
{
if(iamatdm == 0)
{

}
else
{
SendClientMessage(playerid,0xFF0000FF,"You Cant Use Commands In Dm Area!!");
}
return 0;
}



Learn how to code

Reply
#3

errr thats the weirdest command ive ever seen made did you just try to make this up.?
Reply
#4

wow what the fuck is that


https://sampwiki.blast.hk/wiki/Creating_Commands

^^
Reply
#5

NO, I KNOW HOW TO MAKE A COMMAND. I have used the search function to disable commands INSIDE A DM AREA! I've pasted this code from a topic.
Reply
#6

Quote:
Originally Posted by saiberfun
lmao look like he just randomly thought adding stuff like that works see its the weirdest thing ive ever seen lmao.
Reply
#7

Quote:
Originally Posted by speedruntrainer
NO, I KNOW HOW TO MAKE A COMMAND. I have used the search function to disable commands INSIDE A DM AREA! I've pasted this code from a topic.
Well Its 100% Wrong i can tell just by looking at it you havent done nothing but copy and paste and hope read the wiki link.


https://sampwiki.blast.hk/wiki/Creating_Commands

Reply
#8

Lol I already know, But, I mean,
You can't use /healme and /jetpack at some dm zones I scripted, that's what I mean. I found this code under OnPlayerCommandText in this topic: http://forum.sa-mp.com/index.php?topic=98747.0
Reply
#9

At least's hes willing to learn, for fucks sake if you seen someone try to backflip or something and failing epicly you wouldnt stand there laughing at them telling them they've done it wrong.

This is the same thing on a smaller scale.

First thing mate, follow the tutorial to creating commands, then, once the commands are in do something like this.


Код:
public OnPlayerCommandText(playerid,cmdtext[])
{
  if(!IsPlayerInDMArea(playerid) )
  {
  // Insert your commands here.
  }
  else return SendClientMessage(blablabla your not in the zone);
  return 0;
}
Then do something like this.

Код:
forward IsPlayerInDMArea(playerid);
Public IsPlayerInDMArea(playerid)
{

IsPlayerInarea(blablabla);

}
Do some research in to the ideas I gave you, I need sleep.
Reply
#10






[/quote]

Yes, I will, but I know how to use commands. but I found this about disabling commands in a dm zone but IsPlayerInArea or so is fucking hard to use with min_z and y.
I found this code.
http://forum.sa-mp.com/index.php

Quote:
Originally Posted by saiberfun
I know how to do, I ment this http://forum.sa-mp.com/index.php

Quote:
Originally Posted by Shady91
Quote:
Originally Posted by speedruntrainer
NO, I KNOW HOW TO MAKE A COMMAND. I have used the search function to disable commands INSIDE A DM AREA! I've pasted this code from a topic.
Well Its 100% Wrong i can tell just by looking at it you havent done nothing but copy and paste and hope read the wiki link.


https://sampwiki.blast.hk/wiki/Creating_Commands

http://forum.sa-mp.com/index.php

RIGHT!!! :@
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)