RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
Common Event Call by Skill not working [Resolved]

0 Members and 1 Guest are viewing this topic.

***
Hurr durr
Rep:
Level 87
Hamburger? What Hamburger?
What I mean by the title is the function Common Event in each Skill in the skill tab, I made a Demi skill, and set the common event to it's skill equivalent, and even after several testing, it doesn't work. I'm sure I checked everything involved (the character, class, skill, common event, etc...) and it seems I set up everything correctly.

If you want, here's the common event:
Quote
Line 1: @>Control Variables: [0019: HP] = [1.]'s HP
Line 2: @>Control Variables: [0019: HP] *= 50
Line 3: @>Control Variables: [0019: HP] /= 100
Line 4: @>Deal Damage: [1.], Variable [0019: HP]
Line 5: @>Text: Damage: \V[19]
« Last Edit: January 30, 2009, 08:22:24 PM by Miles Castea »
Current Project:
Altaria: Deus ex Machina (in progress)

*
A Random Custom Title
Rep:
Level 96
wah
Why do you... x50 and then divide by 100? It's the same as dividing by 2. And, most likely, your hero has an odd # of HP and the game can't register fractions of HP.

***
Hurr durr
Rep:
Level 87
Hamburger? What Hamburger?
I learned from a tutorial (on RMXP) on how to do skills like heal % HP, and deal damage by %, aka Demi or Quater. That's what it told me to do. It's not a hero, as you can see, it targets a monster, to be exact, the first one.

I seem to be having a problem with any skill that calls a common event if it is intended to work in battle, and it doesn't.
« Last Edit: January 29, 2009, 02:27:47 AM by Miles Castea »
Current Project:
Altaria: Deus ex Machina (in progress)

**
Rep:
Level 86
Um...so I'm not sure where things are going askew for you.  I copied your exact lines of code (as I didn't see anything wrong with them) and made a common event with them.  I created a new skill called Demi which called that common event, and tested it in battle and it worked just fine for me.

Are you making certain to set that the skills call the event in the "Common Event" area?  If so, then I honestly have no idea what's up, man.  As I said, the eventing is sound; it works just fine. 

***
Hurr durr
Rep:
Level 87
Hamburger? What Hamburger?
Yes, I'm sure. But, for the common events themselves, I always had the trigger as none.
Current Project:
Altaria: Deus ex Machina (in progress)

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Most Mature Member2012 Favorite Staff Member2012 Best RPG Maker User (Scripting)2012 Best MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Use of Avatar and Signature Space2011 Best RPG Maker User (Scripting)2011 Most Mature Member2011 Favourite Staff Member2011 Best Veteran2010 Most Mature Member2010 Favourite Staff Member
Yeah, the eventing looks sound - is the battle you are testing it in special in any way, like with an enemy hidden? Is the first enemy already dead? Or maybe you have another skill with the same name that the hero is actually using? I really don't know what is wrong with that event.

Also, as Moo said, you can just divide by 2 rather than multiplying by 50 and dividing by 100. THe reason the tutorial made it that way is likely because they were showing how to generalize percent, so if you wanted to do 57% or something, but for 50% you can just divide by 2. The rest of moo's post makes no sense though -the game will round a fraction down to the nearest integer, so that is not the problem.

Maybe there's a problem caused by some script? ~ Make sure the common event is running - put a message in there and if it plays that tells us something.

**
Rep:
Level 86
He requested a demo of a game where I made the Demi skill, so I whipped one up together real fast for him. 

But yeah, now that you mention it, will the Demi skill work properly if you target the second enemy?  There may need to be a bit more tweaking done, on that end; that hadn't occurred to me originally.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Most Mature Member2012 Favorite Staff Member2012 Best RPG Maker User (Scripting)2012 Best MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Use of Avatar and Signature Space2011 Best RPG Maker User (Scripting)2011 Most Mature Member2011 Favourite Staff Member2011 Best Veteran2010 Most Mature Member2010 Favourite Staff Member
Nah, it would always hit the first enemy.

***
Hurr durr
Rep:
Level 87
Hamburger? What Hamburger?
Anyhow, I decided to provide screenshots for each window related to the problem in the Database.

http://img172.imageshack.us/img172/3897/characteruq4.png (Character)
http://img150.imageshack.us/img150/4964/classvl2.png (Class)
http://img145.imageshack.us/img145/7343/demicommoneventkf2.png (Demi Common Event)
http://img144.imageshack.us/img144/971/skillwr5.png (Demi skill)
http://img140.imageshack.us/img140/913/testbattletrooppe9.png (Test Battle Troop)

Also, a list of my scripts in use:
Anti Event Lag System by Zeriab (Version 1.0)
Advanced Debug System by Slipknot (Version 1.1)
Change Leader System by Modern Algebra (Version ?.?)
End Battles Results Screen (FF style) by ??? (Version ?.?) (I do know it's Draw Slant Bar is by SephirothSpawn)
Wordlock Chests by Zeriab (Version 1.0)
Change Message stating Miss by Sandgolem (Version 3.0)
Battle Command Memory by Sandgolem (Version 1.0)
Item Encylopedia by GoldenShadow (Version 4.0)
Auto Fix Volume Levels 1/2 by DerWulfMan (Version ?.?)
Item Count by KaotiX (Version ?.?)
Battle Trophies
UMS by Ccoa (Version 1.30)
Bank System by ??? (Has Game_Bank, Scene_Bank, Scene_Account, Window_BankItem, Window_BankNumber, Window_AccStats)
Advantage! by DerWulfMan (Version 2.2)
Luck by Falcon
Taxes by The_Darklord
Demon Book by Momomo (With Comments)
Advanced Weather System by Ccoa
Multislot system by Guillaume777
New Shop Design  by Leon (Version 1.0)
Current Project:
Altaria: Deus ex Machina (in progress)

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Most Mature Member2012 Favorite Staff Member2012 Best RPG Maker User (Scripting)2012 Best MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Use of Avatar and Signature Space2011 Best RPG Maker User (Scripting)2011 Most Mature Member2011 Favourite Staff Member2011 Best Veteran2010 Most Mature Member2010 Favourite Staff Member
And when you put the message into the common event, did it play?

***
Hurr durr
Rep:
Level 87
Hamburger? What Hamburger?
No, and nothing happens, except for the miss. Would my common events called through skill not work because of a script?
Current Project:
Altaria: Deus ex Machina (in progress)

**
Rep:
Level 86
I don't have a lot of scripting experience; I grew up on RM2k, so most of my ability is in eventing, so I can't say for sure.  But you do have a few battle-altering scripts, so I suppose it is possible for that to be causing an issue. 

You could try it the scientific way and remove a script, then test it.  If nothing changes, put the script back and take out another, and so on and so forth. 

But as I said, I don't often use scripts, so I really can't say for certain if that might be the problem or not, but I do know that in both projects that I tested the demi skill, I had no additional scripts added...so maybe?

***
Hurr durr
Rep:
Level 87
Hamburger? What Hamburger?
I fixed it, it was the Luck script by Falcon. X_X
Current Project:
Altaria: Deus ex Machina (in progress)