 |
Castle Paradox
|
View previous topic :: View next topic |
Author |
Message |
deadmccoy I'm not supposed to drink...but I do.

Joined: 05 May 2009 Posts: 13 Location: Point Pleasant, WV
|
Posted: Fri Jun 05, 2009 3:40 pm Post subject: Equipment Check Help |
|
|
This is my script that checks your equipment before battle to determine which attacks are available. There are a couple things that aren't working. I thought I'd include the entire script just in case there was something wrong elsewhere, but the only parts that aren't working properly are at the end with the chainsaw, fist, 2x4. There is a 'Melee' attack that is always available in case you run out of ammo with a firearm weapon. These last 3 checks are so that if you already have a melee weapon equipped then this second 'Melee' attack isn't present. Hope that makes sense.
Code: | plotscript, random-encounters,formation number, begin
if(check equipment (0,1) == item:Shotgun && check equipment (0,2) == item:TNT)
then(teach spell (0,5))
else(forget spell (0,5))
if(check equipment (0,1) == item:Shotgun && check equipment (0,2) == item:Acid)
then(teach spell (0,12))
else(forget spell (0,12))
if(check equipment (0,1) == item:Crossbow && check equipment (0,2) == item:Garlic)
then(teach spell (0,10))
else(forget spell (0,10))
if(check equipment (0,1) == item:Crossbow && check equipment (0,2) == item:Poison)
then(teach spell (0,6))
else(forget spell (0,6))
if(check equipment (0,1) == item:357 && check equipment (0,2) == item:Silver)
then(teach spell (0,3))
else(forget spell (0,3))
if(check equipment (0,1) == item:357 && check equipment (0,2) == item:Holy)
then(teach spell (0,14))
else(forget spell (0,14))
if(check equipment (0,1) == item:9mm && check equipment (0,2) == item:Silver)
then(teach spell (0,3))
else(forget spell (0,3))
if(check equipment (0,1) == item:9mm && check equipment (0,2) == item:Holy)
then(teach spell (0,14))
else(forget spell (0,14))
if(check equipment (0,1) == item:Fist)
then(forget spell (0,4))
else(teach spell (0,4))
if(check equipment (0,1) == item:2x4)
then(forget spell (0,4))
else(teach spell (0,4))
if(check equipment (0,1) == item:Chainsaw)
then(forget spell (0,4))
else(teach spell (0,4))
#-----------------------------------------#
# Random Battles #
#-----------------------------------------#
if(current map == 0)
then(fight formation(formation number))
if(current map == 1)
then(fight formation(formation number))
if(current map == 2)
then(fight formation(formation number))
if(current map == 3)
then(fight formation(formation number))
if(current map == 4)
then(fight formation(formation number))
end
|
_________________ H. progress: 10.0% |
|
Back to top |
|
 |
Spoon Weaver

Joined: 18 Nov 2008 Posts: 421 Location: @home
|
Posted: Fri Jun 05, 2009 3:48 pm Post subject: |
|
|
It's not working because each one turns the melee attack on, meaning you'd have to have all three equip'd if you wanted it to work correctly.
To test that I'm right you might want to see if the chainsaw is working correctly. Since it's last it should in fact be working. If not then there might be being problems.
ANYWAYS, I suggest fusing them together.
Like so:
Code: |
if , begin
check equipment (0,1) == item:Fist
or
check equipment (0,1) == item:2x4
or
check equipment (0,1) == item:Chainsaw
end
then(forget spell (0,4))
else(teach spell (0,4))
|
|
|
Back to top |
|
 |
deadmccoy I'm not supposed to drink...but I do.

Joined: 05 May 2009 Posts: 13 Location: Point Pleasant, WV
|
Posted: Fri Jun 05, 2009 3:52 pm Post subject: |
|
|
Yup. The chainsaw was in fact working. Thanks a bunch. That took care of it! Doi. _________________ H. progress: 10.0% |
|
Back to top |
|
 |
Spoon Weaver

Joined: 18 Nov 2008 Posts: 421 Location: @home
|
Posted: Fri Jun 05, 2009 4:24 pm Post subject: |
|
|
Glad I could help.
btw whats " Doi " mean? |
|
Back to top |
|
 |
TwinHamster ♫ Furious souls, burn eternally! ♫

Joined: 07 Mar 2004 Posts: 1352
|
Posted: Fri Jun 05, 2009 4:54 pm Post subject: |
|
|
Spoon Weaver wrote: | btw whats " Doi " mean? |
A funny sound to indicate a mess-up or general silliness? |
|
Back to top |
|
 |
Spoon Weaver

Joined: 18 Nov 2008 Posts: 421 Location: @home
|
Posted: Fri Jun 05, 2009 5:01 pm Post subject: |
|
|
...right. I guess I've never seen it written before.
Now I feel silly.
Doi |
|
Back to top |
|
 |
Guest
|
Posted: Fri Jun 05, 2009 6:14 pm Post subject: |
|
|
HA! |
|
Back to top |
|
 |
deadmccoy I'm not supposed to drink...but I do.

Joined: 05 May 2009 Posts: 13 Location: Point Pleasant, WV
|
Posted: Sat Jun 06, 2009 5:26 am Post subject: |
|
|
I forgot to log in on that one. Doi. _________________ H. progress: 10.0% |
|
Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|