Jump to content

Need script help with new Geomancy mod


45AARP

Recommended Posts

I've made a mod that allows Gemstones to be used for various buff/defensive magic to give them a real use, but want to find a way to stop the effects from stacking when using the same gem type. The way I have it setup is that each gem (ruby, diamond, etc) has an increasing effect based on the quality (flawed, flawless, etc), but when I use a flawed diamond and a flawless diamond it stacks both at the same time, which I want to avoid for balance reasons. I'm debating on if it should allow different types of gems to stack or only allow maybe 2-3 effects from different gems at a time, but I'm not sure how.

 

 

 

 

 

This is the script I have running if anyone knows what would need to be done to have it do such a thing, and I have multiple scrips for each gem and gem quality.

 

 

 

 

 

 

ScriptName aaaDiamondScript1

 

begin OnEquip

 

if ( GetStage aaaGemQuest > 80 )

playSound aaaGemSound

player.addspell aaaDiamondSpell1

player.removeitem Gem6DiamondFlawed 1

endif

 

end

 

 

 

 

 

 

EDIT: I'm also looking for a way to add a small particle or smoke effect for a second around the player when used, as well as an option menu to pop up asking "Do you want to use x" or something similar so that accidental clicks won't waste a valuable gemstone.

Edited by slapahotribe23
Link to comment
Share on other sites

  • 3 weeks later...
  • 1 month later...

I am sorry, but I didn't really get what the problem was. Maybe it is my poor english. What I understood is that you do not want the effect of different types of gems to be cumulative. I don't know how each gem script is, but the first thing I'd say you have to do is to creat If statements all around the place, so that, when used an x type of gem, you have an If statement saying If ( get (other type of gem effect is active), consecuence: erase the other-type of gem effect. You could do this in half an hour, I think, and with no issues. Hope this is helpfull.

 

EDIT: About the menu asking the player if he wants to use the item, you'll need to make a Message box and a button variable. Display the message box when the item is used, saying whatever you want it to say, and then create the options. I'd look something like this (I assume you've created two short variables: one named Button and another one called whatever you want (nShort in my example)):

 

Begin OnEquip

If ( nShort == 0 )

MessageBox "Do you want to use x gem?", "Yes", "No".

Set nShort to 1

EndIf

End

 

Begin GameMode

 

If (nShort == 1 )

Set Button to GetButtonPressed

EndIf

 

If ( Button == 0 ); this means, if the player pressed "Yes", wich, being the first option, has the value "0"

THE EFFECTOFYOURGEM

Else

Set nShort to 0; this would activate if he chooses "No", wich, turning the nShort variable to 0, would put all back to the start

EndIf

 

End

Edited by PkSanTi
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...