How to check if string1 = string2?
#1

Hey everyone,

Maybe I'm kinda dumb, but I don't really know how to check if string1 = string2.

This is how I do:
Quote:

new IsOwner[20];
GetPlayerName(playerid, IsOwner, sizeof(IsOwner));

if(CarInfo[vehicleid][owner] = IsOwner)
{
SendClientMessage(playerid, 0xFFFFFFFF, "This is your vehicle.");
}
else
{
SendClientMessage(playerid, 0xFFFFFFFF, "You don't own this vehicle!");
RemovePlayerFromVehicle(playerid);
}

But it doesn't really work. When I try to sit into the car it allways says: "This is your vehicle" and let's me drive.
This is what compilier gives:
Quote:

...\car.pwn(125) : warning 211: possibly unintended assignment

Can anyone help me, please?
Reply


Messages In This Thread
How to check if string1 = string2? - by Dirkon - 05.07.2011, 19:40
Re: How to check if string1 = string2? - by [NoV]LaZ - 05.07.2011, 19:44
Re: How to check if string1 = string2? - by SchurmanCQC - 05.07.2011, 19:44
Re: How to check if string1 = string2? - by [L3th4l] - 05.07.2011, 19:46
Re: How to check if string1 = string2? - by Dirkon - 05.07.2011, 19:47

Forum Jump:


Users browsing this thread: 2 Guest(s)