SawQuart Posted August 22, 2009 Author Share Posted August 22, 2009 Put this under scripted tile:Case 1Call PlayerMsg(index,"You are now fishing", BLUE, 0)Call PlayerScriptedItems(index, item=1+1)End CaseThis would give the player a fish when they step on the tile. Link to comment Share on other sites More sharing options...
balliztik1 Posted August 22, 2009 Share Posted August 22, 2009 No. Not at all. Did you paste it all? Link to comment Share on other sites More sharing options...
Owen F Posted August 22, 2009 Share Posted August 22, 2009 i dont know what he means? lol?possibly that playermsg is a command?Call PlayerMsg(index,"txthere",COLOR)is basically the command. Link to comment Share on other sites More sharing options...
SawQuart Posted August 22, 2009 Author Share Posted August 22, 2009 Sorry I accidentally pressed enter in the middle of typing it. Sorry :( Link to comment Share on other sites More sharing options...
balliztik1 Posted August 22, 2009 Share Posted August 22, 2009 No worries. No, that will not work.```Case 1Call PlayerMsg(index,"You are now fishing", BLUE, 0)Call PlayerScriptedItems(index, item=1+1)End Case```There are several reasons. First, PlayerMsg has only 3 parameters. The 4th is used in BattleMsg, but not PlayerMsg. Second, there's no command called PlayerScriptedItems, and item=1+1 is not valid syntax. If you are giving an item, I suggest grabbing up an inventory script. Godlord's is quite popular. Check out the script database. The command then would be GiveItem(index, item, amount). Last, you don't need an "End Case". It's not a valid keyword.Do these things and you'll have something like this:```Case 1 Call PlayerMsg(index,"You are now fishing", BLUE) Call GiveItem(index, FISHITEMNUMBER, FISHAMOUNT)``` Link to comment Share on other sites More sharing options...
Owen F Posted August 22, 2009 Share Posted August 22, 2009 although; im pretty sure there is still a command without using an inventory script that will do just that; It's bigger though :Psomething like SetPlayerInvItemSlot (okay so not that but something or other) Link to comment Share on other sites More sharing options...
balliztik1 Posted August 22, 2009 Share Posted August 22, 2009 Yeah, there are other options, but it's the same thing as those functions. You loop and find an inventory slot then change the data there. It's just that you'd only need one line to do so instead of like 10 if you just had a pre-made function.Functions are your friends. :3 Link to comment Share on other sites More sharing options...
Owen F Posted August 22, 2009 Share Posted August 22, 2009 @Balliztik1:> Yeah, there are other options, but it's the same thing as those functions. You loop and find an inventory slot then change the data there. It's just that you'd only need one line to do so instead of like 10 if you just had a pre-made function.> > Functions are your friends. :3I know. I was just saying that anyway in case 'somehow' he can't install an inventory script.functions are awesome i know xD Link to comment Share on other sites More sharing options...
SawQuart Posted August 22, 2009 Author Share Posted August 22, 2009 What about if I want a chance of a fish, plus some fishing exp. Link to comment Share on other sites More sharing options...
balliztik1 Posted August 22, 2009 Share Posted August 22, 2009 @[SawQuart:> Jungletoe link=topic=50718.msg529702#msg529702 date=1250984947]> What about if I want a chance of a fish, plus some fishing exp.That's where things get fun. Check out the Rand(), GetVar(), and PutVar() commands. You can generate a random number, do your calculations as such, then award EXP or not. The EXP will be placed inside a .ini file, added to the value that's already there.There's a ton of fishing/skill scripts out there. Check out what they did if you're confused on how this works. Link to comment Share on other sites More sharing options...
Owen F Posted August 22, 2009 Share Posted August 22, 2009 putvar and getvar for quests eh? that's why i made [this script](http://www.touchofdeathforums.com/smf/index.php/topic,50568.0.html) :) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now