Why won't this work?

Out of curiousity, why won’t this work? I mean it works, it adds the guild, but it ignores the money and client.guild flag. Any ideas, or tips to fix this?

if (playerchats&&strcontains(#c,/createguild)) { if (!client.guild&&playerrupees>=5000) { tokenize #c; setstring client.guild,#t(1); say 1; triggeraction 0,0,gr.addguildmember,#t(1),#a; }else setplayerprop #c,You either don't have enough money, or you already made a guild!; }

Have you tried just doing if (strtofloat(#s(client.guild))==0) or (strequals(#s(client.guild),)) instead of !client.guild?

Also perhaps you should add something to it adds the guild name to a server array and check it prior to guild creation so people can’t break into each others guilds.

I’m no good with that kind of stuff, you know that. I’m a leveler more than a scripter. How would I go about that? Could you possibly start it for me, and I’ll see if i can finish it…

if (playerchats && startswith(/createguild,#c)){ tokenize #c; if (strtofloat(#s(client.guild))==0 && playerrupees>=5000 && !strcontains(#s(server.created_guilds),#t(1))) { addstring server.created_guilds,#t(1); playerrupees-=5000; setstring client.guild,#t(1); say 1; triggeraction 0,0,gr.addguildmember,#t(1),#a; } else setplayerprop #c,You either don't have enough money, or you already made a guild!; }

Done, 1 minute of coding right there :0

[QUOTE=tricxta;85526]

Done, 1 minute of coding right there :0
[/QUOTE]

Thanks, buddy. :slight_smile:

1 minute yeah right, lol

Tricxta has had a lot of experience in coding so I wouldn’t doubt it took him around a minute…

[QUOTE=tricxta;85526]

if (playerchats && startswith(/createguild,#c)){ tokenize #c; if (strtofloat(#s(client.guild))==0 && playerrupees>=5000 && !strcontains(#s(server.created_guilds),#t(1))) { addstring server.created_guilds,#t(1); playerrupees-=5000; setstring client.guild,#t(1); say 1; triggeraction 0,0,gr.addguildmember,#t(1),#a; } else setplayerprop #c,You either don't have enough money, or you already made a guild!; }

Done, 1 minute of coding right there :0
[/QUOTE]

[QUOTE=hosler;85532]1 minute yeah right, lol[/QUOTE]
:drugs:

You’re just jelly

make a good server then

Give ‘im the ol’ one-two! ROFL

[QUOTE=hosler;85539]make a good server then[/QUOTE]

I could say the same for you?