Exxsamuari Posted August 24, 2012 Author Share Posted August 24, 2012 **CHECK OUT** [oÇɹo](http://www.touchofdeathforums.com/community/index.php?/user/67363-o%C7%9D%C9%B9o/) **VERSION FOR NON HARD CODED VERSION OF THIS SCRIPT [HERE](http://www.touchofdeathforums.com/community/index.php?/topic/129037-ammo-for-range-projectiles-30-not-hardcoded/)**ok i made a easy script to make your projectiles take ammunition like arrows and spells to have runesTHIS IS ALL DONE SERVER SIDEMake Sure Item 2 Is Projectile AmmunitionMake Sure Item 3 Is Spell AmmunitionMake sure the Ammunition is Currency so you can stack it–-Projectile---In Private Sub HandleProjecTileAttackUnderDim curProjecTile As Long, i As Long, CurEquipment As LongAddIf HasItem(Index, 2) <= 0 ThenCall PlayerMsg(Index, "You Dont Have Any Arrows!", BrightRed)Exit SubEnd IfCall TakeInvItem(Index, 2, 1)---Spell---In Public Sub BufferSpellUnder' make sure the classreq > 0If ClassReq > 0 Then ' 0 = no reqIf ClassReq <> GetPlayerClass(Index) ThenCall PlayerMsg(Index, "Only " & CheckGrammar(Trim$(Class(ClassReq).Name)) & " can use this spell.", BrightRed)Exit SubEnd IfEnd IfAddIf HasItem(Index, 3) <= 0 ThenCall PlayerMsg(Index, "you Dont Have Any Runes!", BrightRed)Exit SubEnd IfCall TakeInvItem(Index, 3, 1)And Easy as that you have Ammo For spells Or Projectiles =) Link to comment Share on other sites More sharing options...
Whackeddie99 Posted August 24, 2012 Share Posted August 24, 2012 Code Tags! It's all hard coded, so it has to be item number 3. Link to comment Share on other sites More sharing options...
or3o Posted August 24, 2012 Share Posted August 24, 2012 i was just thinking about this like yesterday! thanks man lol Link to comment Share on other sites More sharing options...
iSnow Posted August 25, 2012 Share Posted August 25, 2012 Nice addition, is there a way to add a checkbox to the spell editor to confirm whether or not it uses ammo? Link to comment Share on other sites More sharing options...
Keny14 Posted August 25, 2012 Share Posted August 25, 2012 Yeah i was searching for this a long time ago, thank you bro! ![:D](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/biggrin.png)But> Nice addition, is there a way to add a checkbox to the spell editor to confirm whether or not it uses ammo?And can make special Ammu for only one item choose, and no one ammu for all items. Thanks. =) Link to comment Share on other sites More sharing options...
Joyce Posted August 25, 2012 Share Posted August 25, 2012 This is kind of a lackluster way to do it.. Why not make a checkbox "Requires Ammo" and a dropdown box that lets you pick the ammo item? Link to comment Share on other sites More sharing options...
Vus Posted August 25, 2012 Share Posted August 25, 2012 > This is kind of a lackluster way to do it.. Why not make a checkbox "Requires Ammo" and a dropdown box that lets you pick the ammo item?Yea, that would be better. Link to comment Share on other sites More sharing options...
or3o Posted August 25, 2012 Share Posted August 25, 2012 hey i posted a tutorial baed on this one that allows you to select your ammo thanks guys for giving me the idea. 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