SA-MP Forums

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

Reply
 
Thread Tools Display Modes
Old 01/07/2016, 01:44 PM   #1
HashiramaDenzy
Little Clucker
 
Join Date: Jan 2016
Posts: 29
Reputation: 10
Cool Command typed and nothing is happening and no message error.

When i typed a command nothing is happening, even showing a mesage. what is the reason of that and how to fix this? thanks

public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/kill", cmdtext, true, 10) == 0)
{
SetPlayerHealth(playerid, 0.0);
SendClientMessage(playerid, 0x00FF00FF, "You respawned!");
return 1;
}
return 0;
}
HashiramaDenzy is offline   Reply With Quote
Old 01/07/2016, 01:54 PM   #2
fuckingcruse
Gangsta
 
Join Date: Nov 2014
Posts: 528
Reputation: 8
Default Re: Command typed and nothing is happening and no message error.

Code:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/kill", cmdtext, true, 5) == 0)
{
SetPlayerHealth(playerid, 0.0);
SendClientMessage(playerid, 0x00FF00FF, "You respawned!");
return 1;
}
return 0;
}
__________________
Hello all,
I am providing my scripting services at very low cost. You can expect a very good result of what feature you actually expect. PM me if you are interested.
fuckingcruse is offline   Reply With Quote
Old 01/07/2016, 02:16 PM   #3
HashiramaDenzy
Little Clucker
 
Join Date: Jan 2016
Posts: 29
Reputation: 10
Default Re: Command typed and nothing is happening and no message error.

still the same, nothing happened..
HashiramaDenzy is offline   Reply With Quote
Old 01/07/2016, 02:18 PM   #4
oktokt1
Big Clucker
 
oktokt1's Avatar
 
Join Date: Jan 2016
Location: Egypt, Cairo
Posts: 141
Reputation: 14
Default Re: Command typed and nothing is happening and no message error.

This problem happening to me too.
Try to chabge he cmd from /kill to /death or any thing else and tell me what happend.
__________________
oktokt1 is offline   Reply With Quote
Old 01/07/2016, 02:30 PM   #5
HashiramaDenzy
Little Clucker
 
Join Date: Jan 2016
Posts: 29
Reputation: 10
Default Re: Command typed and nothing is happening and no message error.

Quote:
Originally Posted by oktokt1 View Post
This problem happening to me too.
Try to chabge he cmd from /kill to /death or any thing else and tell me what happend.
i tried what you said but still the same
HashiramaDenzy is offline   Reply With Quote
Old 01/07/2016, 02:31 PM   #6
fuckingcruse
Gangsta
 
Join Date: Nov 2014
Posts: 528
Reputation: 8
Default Re: Command typed and nothing is happening and no message error.

want a best idea?
Use the ZCMD include, it will be easy and good.
__________________
Hello all,
I am providing my scripting services at very low cost. You can expect a very good result of what feature you actually expect. PM me if you are interested.
fuckingcruse is offline   Reply With Quote
Old 01/07/2016, 02:37 PM   #7
HashiramaDenzy
Little Clucker
 
Join Date: Jan 2016
Posts: 29
Reputation: 10
Default Re: Command typed and nothing is happening and no message error.

Still the same i did what you said
HashiramaDenzy 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
Message to all when typed command ultrAslan Scripting Help 10 10/03/2015 04:25 PM
Command typed, nothing happen Blackazur Scripting Help 3 09/11/2013 12:04 PM
Send Message If Command Typed Ritchie999 Help Archive 2 17/12/2009 08:47 PM
need a command that when typed displays a message on a players screen....:S tregregins Help Archive 3 28/08/2009 04:11 AM


All times are GMT. The time now is 10:44 AM.


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