• Announcements

    • Archeia

      RPG Maker MV 1.3.4 Update!   11/23/2016

      Hi everyone! The Latest RPG Maker Update is here!    
    • Lunarea

      The Calm and the Fury Art Contest   12/16/2016

      We are excited to announce a collaboration with the acclaimed Hiroki Kikuta, composer of many of our favorite RPGs. You can be involved, too, by taking part in our art contest! For more details:  
    • Archeia

      Merry Maker Christmas!   12/24/2016

      Merry Maker Christmas! Free Resources with love from the Restaff & RPG Maker Web Team! http://bit.ly/2isbiyJ  

Search the Community

Showing results for tags 'javascript'.

Found 196 results

  1. -------------------------------------- Latest Plugin: Extended Doodad Pack 1 -------------------------------------- Here are some plugins made for RPG Maker MV, a piece of software that lets you create your own role playing games for the PC, Mac, and various mobile devices! Keep in mind that these plugins are made for RPG Maker MV only! They do not work on other RPG Makers. THIS THREAD WILL BE USED FOR PLUGIN UPDATES, NEW YEP VIDEOS, AND BUG REPORTS! This thread is NOT a request thread. Requests include new plugins, new features for existing plugins, and features that you personally think should exist but currently do not. If you want requests, visit the proper subforum for it; this thread is not the place to do so. To make a bug report, simply report it in this thread. Chances are, I will find out about the bug in this thread than by making one in the JS Support forum. NOTE: Read this before submitting a bug report on this thread: I will only support my own plugins and code that I, myself have provided. If there are bugs with other people's plugins and/or bugs with the RPG Maker MV base code itself, I am not responsible for it. Report it in their own threads if it is a bug for their plugin or the official bug report forum if it is a bug with the RPG Maker MV base code. I am not responsible for bugs created by plugins created by other makers. There will be no compatibility patches made between my plugins and non-YEP plugins. This is not because I disrespect other plugin makers. If I did, I wouldn't go so far as to maximize compatibility with my plugins when possible. The reason behind this is because of my lack of time, and I'd like to put my undivided attention to errors caused by my own plugins. I am not responsible for any Lunatic Mode that you, yourself, have made. If you have created your own Lunatic Mode code that isn't running, go visit the JavaScript Support Forum instead. I am not obligated to explain to you how to code in JavaScript. There are plenty places online to learn it but this thread is not that place. I am not obligated to explain to you how to use all the various functions inside of my plugins. If a function added by my plugins is not listed in the Help File, it means I do not deem that function to be used for script calls. Therefore, if you choose a function outside of the ones listed in the help files to use in a script call, I am NOT responsible for it not working properly for you. No script call support will be provided for functions not listed within the help file. I am not going to "fix" my plugins to work with the Exclude unused files feature that comes with RPG Maker MV. The feature exists primarily for games that don't use plugins or games that use plugins that do not reference other game files. Read about it here in detail. ALL bug reports MUST follow these guidelines and use this template: Plugin Name: (What is the name of the plugin?) Do you have all the latest updates for the plugins in question? (Click here for all of the latest updates and install them. If you do not have the latest updates, I will ask you to remake the bug report) Plugin Parameter Changes: (Mention ALL of the changes you've made to the plugin's parameters. Otherwise, I will revert every single plugin's settings to the default setting) Bug Explanation: (What is the bug in your own words? Keep this detailed. "It isn't working right" is not a valid bug report.) Create a Sample Project Reproducing the bug: The sample project MUST follow all of these guidelines: Create a new project. Do NOT just copy over your game project folders. This should be just a stock, empty, new RPG Maker MV project. If I do not see an empty project with Harold, Therese, Marsha, and Lucius, I will not look any further. The project's file size must be 200 MB or LESS. Remove unnecessary audio and image files until you reach that size or use MV Stripper if you need help doing so. Install -only- the affected plugins. Do NOT copy/paste them over from your project's Plugin Manager. If you're using non-YEP plugins, do NOT include them. That said, I apologize that both ATB and CTB are no longer supported by Yanfly, so if you're using them, please remove them from the project used for the bug report. Do -NOT- rename the plugins' filenames. They will not work if you do so. MAKE SURE you DO NOT change the filename from the file downloaded from the website. Make sure they're in the EXACT order listed on Yanfly.moe. The correct ordering of plugins is important. Some plugins will not work if they aren't in the right order. Do -NOT- deploy the project through File > Deployment. Do -NOT- box the sample project. If I cannot open up the sample project when I get it, you will have to redo it all. Error Report: (If you received an error message, press F8 when the message is received to open up the debug console, then copy/paste the entire error log and paste it here). Exact Steps on How to Replicate Bug: (Write out IN DETAIL, a step-by-step guide on how to replicate the bug.) Did you recreate the bug on the sample project? (If not, do so. MAKE SURE you are using notetags in the right place and haven't misspelled anything. DO NOT USE SAVES. I need to know exactly how to recreate the problem from start to finish. Simply giving me a save file tells me nothing.) Upload the sample project and share the link (ABSOLUTELY REQUIRED): Use WinZip or WinRAR to archive the project. Do -NOT- archive it multiple times. Upload it on a website like Mediafire.com or Dropbox. Do -NOT- use a website that involves timers like 4shared, RapidShare, etc. If I am time-gated from downloading the project, I will ask you to reupload it somewhere else. Post the link here. If you do not include a sample project that meets these guidelines, the bug report will be invalid. There are NO exceptions. WHY I NEED A CLEAN SAMPLE PROJECT FOR BUG REPORTS: If you're wondering why I make it an absolute requirement for sample projects containing to be made, it's because in the past, I've chased and hunted bugs that do not exist either because a user had a conflicting error with a non-Yanfly plugin, has not updated the plugins, using the plugin incorrectly, or think something is a bug when it really isn't. The amount of time I've wasted chasing these "bugs" is unfathomable as that time could have been spent developing new content. To mitigate this issue, I made it an absolute requirement for bugs to be reported in such a manner because of the following: It makes the user go through all of the troubleshooting steps to reduce the amount of user errors. If the user identifies it as a user error, then the user would also have gained troubleshooting skills, which are essential for game development. If you cannot be bothered to learn how to troubleshoot, I'm afraid RPG Maker will be giving you a whole lot more stress later on. Isolate the bugs caused by Yanfly plugins away from non-Yanfly plugins. As stated above, I do not provide support for non-Yanfly plugins due to my lack of time to create compatibility patches for non-Yanfly plugins. Having over 100+ plugins, making a compatibility patch for each one of those with every other plugin out there is absolute insanity. It shows that the user is serious about getting the bug fixed as I am. Being able to put out time to isolate a problem so it can be fixed means the user is serious about getting their game made. If you are not serious about getting a bug fixed for your game, then I have no reason to be serious about getting it fixed for you. As a user's time is important to them, my time is also important to me, and this is our mutual agreement to get things done cooperatively. Thank you for understanding. BASIC TROUBLE SHOOTING 1. Are all your plugins up to date? If they're not, download the updated versions from here: http://yanfly.moe/yep/changelog/ 2. Did you rename any of their plugins from their default filenames? If you did, then the plugins won't work. Do NOT rename them. 3. Did you make sure all of the plugins are placed in order as http://yanfly.moe/yep/ inside of the Plugin Manager? 4. When you updated the plugin, did you /open up/ the plugin within the Plugin Manager? You are getting the error because you updated the plugin and did not go into the plugin itself like the instructions here in the first video: http://yanfly.moe/yep/changelog/ Why is this important? Because whenever new parameters are added to a plugin upon a new update, you have to enter the plugin in order for the Plugin Manager to add those new parameters into your game. Otherwise, you will get undefined errors and "random" crashes. Skipping that step is not optional and is very crucial to getting updated plugins to work. 5. If you are using non-Yanfly plugins, turn off ALL of the non-Yanfly plugins to see if there are any conflicts. 6. If you are testing your project in Battle Test and aren't seeing any changes made after updating your plugin, make sure you -save- your project. RPG Maker MV does not carry over changes to Battle Test until you save your project. F.A.Q. ABOUT ATB AND CTB PLUGINS The ATB and CTB plugins are custom battle systems that do NOT involve a turn-based system that you're used to with the default turn-based battle system (DTB). They function off of a tick-based system, which means it does not work off standard means. This also means you have to adjust either the plugin or your game to fit these means. Here are some frequently reported "issues" with the system. None of these are bugs so do not report them as bugs. If ATB bars are taking too long to fill up, then change your battlers' AGI values to higher or change the plugin parameters to fit your game. If ATB states are dropping in turns too quickly, this is because you didn't adjust the proper state turn settings within the Battle Engine Core to fit your game. For ATB, no, I will NOT make Active Mode. It's not because I can't (I've made it before in VX's Yanfly Engine Melody). It's because RPG Maker MV's code structure for the battle system makes it more likely to break everything if it does so. If this is something you absolutely need, the Plugin Request Forum is your place to visit, if DoubleX RMMV Popularized ATB Core(which is at least compatible with my Battle Engine Core with the compatibility fix) can't meet your demands already. If there is "lag" between CTB turns, this isn't because of the plugin. This is because your low AGI values is making the game go through hundreds to thousands of CTB updates per tick. Once again, either you increase the AGI values or change the plugin parameters to fit your In CTB, States "skipping" multiple turns when updating isn't a bug. It is because in between the previous battler next battler, there was a huge gap in time, enough to go through two state turn cycles. Adjust the state turn settings within the Battle Engine Core to fit your game. For CTB, no, I will NOT make multiple instances of turn icons appearing for multiple actors. If you want something like that made, you can request it in the Plugin Request Forum. If all of these issues are beyond you, then I'm afraid the ATB and CTB plugins aren't for you. As a developer, it is your responsibility to understand the plugins and systems you are using. You are not doing your players any favor by using a system that you, yourself, do not fully comprehend. I will not educate anyone how ATB and CTB systems work. My plugins work based on the ATB and CTB systems of existing Final Fantasy games with slight tweaks to fit RPG Maker MV's system. Please study them on your own accord. TERMS OF USE HOW TO INSTALL PLUGINS And below are the plugins I've made. I strongly recommend that you place these plugins in the following order if you plan on using them. The plugins here will link to the individual posts on this thread for more detail.
  2. Time Travel Plugin?

    Hello! I've been looking for a plugin that can allow a player to time travel in my game. I haven't found anything, but I was hoping I could find some pointers here. This is what I had in mind for the plugin. 1. Say the player presses an assigned button on the keyboard. Lets say "A" for simplicity. 2. A command window will pop up with "Travel to..." with the options "Travel to Past", "Travel to Present", "Travel to Future", and "Return". 3. When the player selects, for example "Travel to Past" all it would do is transfer the player to a different, altered version of the map that they are in now. 4. I'd like it to have it set where the player would be in the same co-ordinate that they were at in the previous map. For example, if the player was at (8, 9) on map "Future", they'd still be at (8, 9) on map "Past". EDIT: Blugh, my post keeps getting published before I'm ready to. Habitually pressing the Tab Button to indent. So, if this can be Evented, that'd be fantastic! If it'd be more efficient to script it, I'm open to learning Java and will gladly listen to pointers. Thank you for reading! Have a lovely day/night, where/whenever you may be!
  3. Good day everybody, Is there a javascript command to access and manipulate the event comment? I am aware of the '$dataMap.events[n].name', but '$dataMap.events[n].comment ("blaba');' or '$dataMap.events[n].comment = "bla"' doesn't seem to work. Thank you in advance! Regards, Fumetsujo
  4. This is my first real attempt at a plug in so I'm trying to do something simple but useful. Looking to be pointed in the right direction. Hopefully this is the right place to post it. There are active mods here they'll make sure I get it right. Goal: To keep track of the number of uses for a skill, item or weapon. This number can than be used in the effect formula. Example: Skill Fire has been used by Actor George 100 times. His damage for the skill fire is more effective than for Actor Marian who has only used it 50 times. Simple Damage formula a.mat + a.actionXP/5 In our example above, assuming both George and Marian both have a magic attack of 50, then George would do 70 damage and Marian would do 60. After the call skill use gets ticked up one. This is all handled behind the scenes by the battle manager. I'm going to start with skills and then use the same theory for items and weapons later. What I have so far: What I know I'm missing: --- For every skill in skillXP for the actor I need to add a spot in the array. I don't know if I should do that when the game first loads... or if maybe I can push into the array an object with the skills name and then save the xp variable in that object each time I call the effect in the damage. I'm not sure. Any suggestions? I'm going to play with it, but any help is appreciated. --- I know I'm missing other stuff too, but I'm unconsciously incompetent on a lot of this, so I have no idea what else I could be missing. I'm just aware of my own shortcomings.
  5. Hi there, this is my Flip a Coin Minigame. Because I started learning JS two days ago, I decided to start small. How to implement: Copy the "PINC_CoinFlip.js" into your /js/pluginCopy the "head.png" and "tail.png" into your /img/picturesAdd PINC_CoinFlip in your Plug-in-ManagerEdit parameters if neededEdit: Demo I created a Demo for you guys, so you can see how to use the plug-in. The coin-animation I created may be used together with the script. Download: https://www.dropbox.com/s/w5xrjkp8jw3aogv/PINCALIBUR_COIN_FLIP.zip?dl=0 Script only I hope you enjoy my first Plugin! If you want any additionally features, tell me. I would like to be credited, if you use my ressources! If you release a game and you use my ressources ,I would be happy to play it! Thank you
  6. Introduction Hello, everyone! It’s time to discuss ES6, or JavaScript in RPGMaker MV(RMMV). Most code in RPGMaker MV is written in ES5. RPGMaker MV is an engine running on NW.js (or Node-webkit); the version is older (nw.js is 0.12.3), however this still allows developers to use some ES6 syntax inside of their code alongside ES5 code. To start of, I’ve decided to gather most of the features that work in RMMV. Here’s a list of ES6 features available in RMMV. Features Block Scoped Variables Objects Object Assignment Shorthand Object Properties Method Properties Template Literals Expression Interpolation Multiline Strings Classes Class Inheritance Base Class Access Getters and setters Symbols String Methods Repeat Starts With Includes IndexOf Numbers Type Checking Safety Checking Number Comparison Truncation Sign Determination Sets and weak sets Maps and weak maps Each of these features can enhance your code in some way as you’re developing your plugins. Furthermore, you can use them in tandem with regular ES5 code; that’s the most important point to make. In future posts, I’ll go over each feature in depth, and give you a general idea of how each one can improve your code in some way, as I’ve started using ES6 in my JavaScript. Finally, if you enjoyed this small tidbit of information, or you think you’d like to know more, please comment down below and stay tuned!
  7. Alpha ABS Issue

    Hey guys, Hopefully this post isn't redundant, so I'm pretty close to release and trying to embed this game on my website, but I keep getting this error when I click "New Game". If I run the game normally on my phone or PC it runs just fine, but only on the website it throws these errors. I've been driving myself crazy trying to change stuff to get this to work. The creator of the plugin is on vacation, I've posted in the actual thread for this plugin with no respnse. If I turn off the ABS it works just fine in the browser, but the ABS is pretty essential to this game. Things tried so far: -I moved the plugin all the way up in the list and keep getting this error. -Turned off all other plugins -Turned off just Alpha ABS (this fixes it, but without the abs this game is kinda nothing) -Tried to check for issues in the game itself to get this to work I'm sure this is a problem with the plugin itself, but I'm at a complete loss here. Anyone have any suggestions?
  8. Hi all! New to the forums here but hoping I can get some help! I'd like to know how I'd be able to do the following during battle: When actor A uses a certain skill (which we'll call Skill5 for fun) on one of the other actors, it changes a variable that is dependent. For example, my variables would look like this: 001 Actor A's Variable 002 Actor B's Variable 003 Actor C's Variable etc... So if Actor A used a skill on Actor B, it would change Actor B's Variable, or variable 002, by -1 I'm using a few Yanfly plugins, including YEP_SkillCore, which in lunatic mode almost has what I'm looking for but alas I am no lunatic and have no idea how I'd implement it where it is determined by who is being effected. Here is a snippet from the plugin which I think is useful: Example: <Custom HP Cost> code cost += $gameVariables.value(1); code </Custom HP Cost> </Custom HP Cost> Any help is greatly appreciated!!
  9. Seki_Summon V1.02a by Sekunri Introduction This plugin allows you to create skills that summon new actors not in the party into combat. A new version of this plugin will be making the plugin obsolete. If you have any feature requests please post them below and I'll see what I can do. Features Requires a bit of setup, check How to Use below for the basics. Plug & Play Allows you to summon persistent actors into combat up to 8 maximum in battle including your party and the summons. Unlike with previous battle party manipulation plugins you can have as many party members as you want and the summoned actor will not interfere with your party's order or appear invisible! Allows you to customize your parties positions How to Use Installation is easy. Just plug it in and it should work. It is recommended you use Yanfly's Base Troop Events or Shaz's Battle Result Switches as well. The help file provided has the commands and special notes on them. You can also view them in the spoiler. You will need to setup a few things to properly use this plugin. With those steps completed you can now use the Summon plugin command without any trouble. Screenshots Reported Bugs When using YEP_PartySystem will summon 2 actors if you are using the Troops Test feature in the database. Compatibility Issues (none so far) Download V1.02a Change Log V1.02a : Added Battle End Switch to remove the need for Base Troop Commands to set a switch at battle start. Edit by Michael Caiola. Permission to use Battle Result Switch's code granted by Shaz. V1.01a : Added the Dismiss command to make clearing summons easier. Added translations to functions. FAQ Q: The shadow is too small, how do I fix that? A: Unfortunately it wasn't until I ran tests with larger sprites that I noticed that. I will be fixing that. Q: I want to create a Dismiss skill but when I dismiss the summon an actor in my party appears! A: Assuming you used the Dismiss command you should follow it up with the MinusBattler 1 command as well. Q: The summoned Actor is dead and won't go away during the battle. A: You'll have to use the Troops Command pages to do that. It'll require a bunch of conditional branches that dismiss actors when they have the Knocked Out state, refer to question above. Again this plugin is very basic in its current version and works best with Yanfly's Base Troop Events for this purpose. Q: The summoned Actors are still in my party what gives? A: Read How to Use above. Make the switch and the common event. I'll be trying to fix this in the near future, sorry for the inconvenience. Q: Why would you use PlusBattler? A: As the plugin functions in its current version (1.01) the summons move on screen from the right. This will be patched in the future but PlusBattler will still allow you to "call for reinforcements" from your inactive party as well. Q: Why would you use MinusBattler? A: Let's say you have 4 actors in your battle party but want to create a fight where only 2 of your actors take part in the fight. Normally you would have to remove your actors until you had only 2 left and then the rest of the party can't get reserve EXP. With this command you can just lower the amount of active fighters so they can still earn EXP. Or do some evil things I won't openly discuss. Q: Why did you make this plugin to work with someone else's plugin? A: I didn't specifically make it to work with Shaz's or Yanfly's plugin, it just so happened that the synergy was there. Both of these developers have done a lot for us so why shouldn't we use what they've given us? Credit and Thanks - Credit to Sekunri - Thank you to Shaz for their Shaz's Battle Result Switches Plugin which has been integrated & for answering questions I had on the forums. - Thank you to Yanfly for their programming format. - Thank you Michael Caiola for your edit and plugin advice. - Thank you to all supporters of this plugin. Usage Free to use for commercial and noncommercial RPG Maker games as long as you credit Sekunri and it'd be awesome if you would link me to your finished product. Author's Notes - If you have any questions or suggestions feel free to let me know. - This was my first real script so i apologize if its a bit unpolished. - Please do not post the plugin itself elsewhere and instead redirect to this thread. Thank you.
  10. M.U.G.E.N.-based Battle System Hi everyone! I hope you're having a very nice 2017 start! I came here to request something "peculiar" for the RPG genre, something that was born out of my head after hours of playing. Well, let's start! Introduction There is a lot of fans of RPGs and Fighting Games. What about unite both? This is my idea. A blend of both systems. It was born after I started playing MUGEN a lot, and I was thinking about how tedious sometimes the battles of some RPGs could be (mainly the ones like Final Fantasy and Chrono Trigger, or strategy). So I said: Why not use a MUGEN (or the more know: Street Fighter and Mortal Kombat)-like battle? It's more dynamic and depending of the game story it could work. Well, enough of history. Now i will detail what the hell is M.U.G.E.N. *Please note i'm not requesting a straight port of MUGEN engine for RMMV. Only the concepts of the gameplay, which are similar in all fighting games. Besides that, MUGEN is closed source and i doubt Elecbyte will ever release the source code.* What is M.U.G.E.N.? According to Wikipedia: Now some Videos showing exacly how MUGEN (and any game of this kind) works: (the vanilla character kung fu man) A mod for MUGEN adding Mario and related characters. Skip to 0:38 Well its just for the interested scripters get a notion about how MUGEN works. The Plugin Now I will show the most important parts of this request: The Battle The battle would take 3 rounds, the first to win two is the winner. There would be a configurable time for each round, or no time using the infinite symbol like in the image. The yellow bar represents the character's HP and the blue bar in MUGEN is the Power Bar (an equivalent of this would be FF7 limit break or Chrono Cross elements unlockables), but in the plugin it can be basically the player's MP, but if the creator wants to add the power bar system it would be nice. The Techs/Combos Basically, all the player techs would be turned to combos. According to MUGEN wiki: Additional Elements Plus the things i said above, other elements that could be added in the system if possible are: Red Health; the Hyper moves (just like limit break); The different AI types Well, from my head is this. Sorry if i wasnt clear, my English isnt perfect.
  11. hi am trying make a easy way to auto increase a variable . in this example, so when i showPicture , the var PID and defxy[1] need to increase after show. Is work good for ++, but not the += function ActionKey(WhatToDo) { var PID = 83; // default PID for actionkey huds var defxy = [1200,500]; // default x y pos for actionkey var PH = 125; // picture fixed heigth from Action-Key.png if (WhatToDo==='show') { $gameScreen.showPicture(PID++, 'Action-Key', 0, defxy[0], defxy[1]+=PH, 100, 100, 255, 0); $gameScreen.showPicture(PID++, 'Action-Key', 0, defxy[0], defxy[1]+=PH, 100, 100, 255, 0); $gameScreen.showPicture(PID++, 'Action-Key', 0, defxy[0], defxy[1]+=PH, 100, 100, 255, 0); } } The way clearer. Why does this return me 5, 6 and not 5, 5 ? var A = 5; var B = 5; console.log((A++)+ ' ' + (B+=1)); // return 5 6 That fµ©£ me, all the easy way, with which I would like make my code. Is there a way? or is a buggy javascript ?
  12. hi, im use really long actor names and i have a main class and subclass, but the actor name overlaps onto the class/subclass. I've been messing around with javascript in the rpg_windows.js file, and this is what I found but can't figure out what to do to solve this problem. this line of code works if i modify it but changes global text to whateve i do with it. Window_Base.prototype.drawText = function(text, x, y, maxWidth, align) { this.contents.drawText(text, x, y, maxWidth, this.lineHeight(), align); }; this line of code if i modify nothing changes no matter what i do but (seems like it would solve my problem if i could figure out how to get this line to actually modify in game text) Window_Base.prototype.drawActorClass = function(actor, x, y, width) { width = width || 168; this.resetTextColor(); this.drawText(actor.currentClass().name, x, y, width); }; this line of code seems interesting but doesnt do anything either when i try to modify it. Window_Status.prototype.drawBlock1 = function(y) { this.drawActorName(this._actor, 6, y); this.drawActorClass(this._actor, 200, y); this.drawActorNickname(this._actor, 432, y); }; the only thing that modifys and works but not correctly is using this line of code Window_Base.prototype.drawText = function(text, x, y, maxWidth, align) { this.contents.drawText(text, x, y, maxWidth, this.lineHeight(), align); }; like if i change align to = 'right' or 'center', it changes the actor name/ class/subclass to align right or center but its GLOBAL so it changes all the text. not specific to my problem. I spent 24 hours trying to figure this out, but no luck, please if you know anything please help...
  13. so I have a code which looks like this if (item.meta.max) { return eval(item.meta.max); }; With item.meta.max being "$gameVariables(1)" but when the code is called, it returns an error that says object is not a function. the nodekit console points to item.meta.max line during this error I already made sure that item.meta.max returns "$gameVariables(1)" via a show text event so somehow eval doesn't seem to want to evaluate it.. Anyone has an idea of the problem here?
  14. This thread is not directly related on coding or programming in Javascript, but on sharing thoughts about some things on Javascrpt, so I post it on General Lounge. First off a WARNING. I am neutal to Javascript. I love to hear different opinions and that is why I create such threads. But if any random wild drama queen emerge, I will be the first person reporting this thread to close. So, NO DRAMA. Nobody is against Javascript and this thread is not a debate on "What programming language is the best?". There is no answer to that anyway. The programming language that solves your problem optimal for YOU, is the best programming language for YOU, for the CURRENT job YOU do. Everyone has different needs, end of disucssion. The topic is different and I hope better than that. So I realized, that everyone teaching Javascript these days tell people that new properties and methods can be added to objects at any time in a program. This is true and one thing that makes Javascript flexible, but it is also a huge problem. That is taken most of the time wrong. And it's not the learner's fault. What is wrong is that the prototype design must be correct and solid. Otherwise bad things can happen. The bad attitude that has passed through weak tutorials is that if someone will declare a prototype, but if the design is weak and wrong, "oh well, they can fix that by adding something here and there". THIS is one of my greatest objections on JS as a "first learning programming language" or "learning programming language" in general. It gives you the power to make terrible code that will actually work. Most people think they know how to program, while they make code ready to be served to an italian restaurant (google spaghetti code). There is a debate: "If it works, I don't really care. It works for me." True. But what if you revisit the code after six months and don't remember what on earth is going on? Commenting will not help a loose design. Most important what if your code is about to be shared with other people? What if you make a plugin for instance? Making solid prototypes helps you make solid code, without adding or removing much attributes or methods everywhere. That makes the code easy to maintain, debug, expand and modify, while having a loose approach can make it very hard to maintain the code. So after sharing some thoughts, here comes a bunch of questions. 1] Do you believe that solid prototypes should be taught or not? Do you believe it is an issue that newcomers in JS create terrible code sometimes? I met many IT guys telling me they hate Javascript. But what I realized after long conversations was that they don't really hate the language. They hate how people use it. 2] Do you believe JS is good for beginner programmers? From one side they can make spaghetti code, on the other hand, you got ease and flexibility. I mean it is REALLY debateable. I learned to code in QBasic when I was 14 years old, when all I had was terrible code examples full of GOTO commands. I am dead serious, there was no internet back then. But I ended up programming well and if you ask me, QBasic wasn't a bad language. I just lacked a good tutorial on structured programming. 3] Tell me a few things you LOVE on JS. 4] Tell me a few things you dislike on JS. I want to get a bigger picture and maybe this thread would be useful to more people in the future. P.S. My JS level is newcomer, but I learn really fast, because I already know how to code on several other languages. STILL I am a noob on JS and that's why I make such a conversation.
  15. My current plan is that once I get a job I am going to pay for coding lessons on some website. What website should I use for this? And (I ask this to the script makers) how long did it take learn javascript before you could start making some of the more complex scripts?
  16. I seem to be having a little unexpected trouble here. I'm trying to create a system that requires new arrays and, ideally, functions. The problem is that no matter how I code the declaration of these things, the game returns "ReferenceError: x is not defined". Here's my current code for example: The idea was to test if the "members" index function worked on normal arrays, in hopes of bypassing the need to code a function to index a specific array. At that time I thought only my functions weren't getting defined, but unfortunately, it appears to apply to variables as well. I've also tried it as... Every time I'm met with the same result. My guess its that I'm unaware of a very specific way RMMV reads the code that runs a little different to what I picked up in basic Javascript tutorials. If anyone knows what I'm doing wrong, I'd appreciate a bump in the right direction!
  17. Active party list

    Greetings! I've been using the excellent questions and answers on this forum through searches alone for a while now, but I couldn't find this topic, so I thought it was time to sign up and ask. My Goal: Have a choice box pop up in which each choice displays the name of an active party member, and contains an if/else statement that triggers a swap between one party member, and another who's temporarily sitting it out. I achieved this very easily in the editor, but now I'm trying to code it as part of a function. The problem with this is while I found a spreadsheet with a bunch of MV syntax, I don't for the life of me understand the Choice syntax. This is probably a fairly easy problem to solve, so I apologize for the question. I just look at all those brackets and quotation marks and words and my brain shuts off. I'm an absolute novice with zero programming education and an absolute total of about a month of Javascript experience, and these are the kinds of questions that tend to arise in my situation. Thanks in advance.
  18. Hi all, so I'm trying to add a twist to Yanfly's Row Formation script and instead make something similar to the system in Darkest Dungeon. In a nutshell, both allies and enemies have 4 rows, and each can only be occupied by 1 character. Skills have a user requirement (must be standing in a certain row) and can only target certain rows (e.g. Slash can only be used by someone in Row 1 or 2, and can only hit enemies in Row 1). Some Skills move you around, but you can also do it the hard way and spend a turn moving. Whenever you move, you shift the party around. If someone in Row 1 moves back to Row 2, whoever is in Row 2 moves to Row 1. If someone in Row 1 moves back to row 3, whoever is in Row 2 moves to Row 1, and whoever is in Row 3 moves to Row 2. (you can also just click the link and watch their battle system in action). I'm not very good with scripting, but I did manage to make moving in battle work using Skills that move you and an ally at the same time. What I don't know how to do is add the ability to move around outside of battle. Yanfly's Row Formation script has a Row Menu that you can open up both inside and outside of battle, but I can't use this because from a lot of searching, no one seems to know how to make it so that only 1 character can occupy 1 row. Without the ability to change rows outside of battle, it becomes a little tedious. I think I have an elegant solution, but I can't script my way out of a paper bag, so some help would be nice: What I need is a way to control Rows using the Party Formation menu, NOT the Row menu. You know the Formation option in the menu that lets you reorder your party? That has very little use, but what if we set it so that whoever is first on the party formation will be in Row 1. Whoever's second in Row 2. Third in 3. Fourth in 4. If you happen to have more party members than the number of rows, nothing would happen with them, so Fifth in the position will not be in Row 5, he'll just not be in the party, same with Sixth, Seventh and so on. With a Party Formation like the above Row 1, 2, 3, 4 would be Harold, Therese, Marsha and Lucius. If you shift it around like the second image, Row 1, 2, 3, 4 would be Marsha, Therese, Harold, Lucius instead. If possible, this formation should also reset at the end of every battle, so let's say you go into battle with the row order of Harold, Therese, Marsha and Lucius. You move Harold back to Row 2 and Therese takes his place. You win the battle with the row order of Therese, Harold, Marsha and Lucius. When you go back to the map, you revert back to Harold, Therese, Marsha and Lucius. Tl;Dr How do I make it so that I control the Row using the Party Formation menu instead of the Row menu? Where the first in the party will be in Row 1, second in Row 2, etc. Thanks in advance.
  19. hi i know i can do the function with (for) and (loop), but logically, am supposed to be able to get the indexOf ? Why my function to search index in a 2D array alway return me False (-1) ??? If you add this to console.log //------------------------------------------ gate1=[]; gate1=[[3,4],[4,6]]; // test [[ItemID,NBItem],[ItemID,NBItem]] //------------------------------------------ function CheckGiveItem(ID, NEED, GVariable) { var found = [ID[0],NEED[0]]; // = [3,4] return GVariable.indexOf(found); } //------------------------------------------ $dataArmors[1].meta.test = { //test indexof 2D array check: CheckGiveItem([3,6,10,11],[4,6,8,7],gate1) //example ([ItemID],[NEED],GlobalGameVariable) }; and after this to test $dataArmors[1].meta.test.check is return me -1 i do the same thing like i read here. http://stackoverflow.com/questions/1427640/indexof-syntax-for-multidimensional-arrays
  20. Javascript in rpgmaker mv?

    I thought Javascript must be used inside html's script tag,but why rpgmaker mv doesn't have a script tag or any tag in the source code?
  21. Hi i have issue with Number() function. WhereAreYouinGalaxi = []; function QuestMenu(WhatToDo) { WhereAreYouinGalaxi = [Number($dataMap.meta.Galaxi),Number($dataMap.meta.Planet)]; //[Galaxi,Planet]; } Why my var WhereAreYouinGalaxi return ['0','0'] and not [0,0] ??? console.log(WhereAreYouinGalaxi); == ['0','0'] ??? Tanks for helping
  22. So in a game I'm working on, I have an actor who reflects magical attacks of most elements. Because of this, I want the stronger, more intelligent enemies in the game to know this and, during battle, not target her with their unique magical attacks. Yanfly's selection control plugin has a note tag to enforce this, but it can only apply to actors universally, which would render her elemental reflection completely useless and then no less intelligent enemies could target her with any magical attacks at all. However, you can also set custom conditions for targeting on skills using Javascript, apparently. But having no knowledge of Javascript's language whatsoever, I don't know what to do to make this. Basically, I need a JS command that checks to see if the target's name is NOT this specific character's name, and if that condition returns true, then the attack goes through. If I knew how to check to see if something is not equal to something else in Javascript, I could do it myself, using the handy example on the plugin's info page (link here) as a base. So could someone please help me out with this? Either by posting a modified version of the command on the plugin page or just telling me how to check for something not being a certain way so I can modify it myself.
  23. Just as the title says, I'm looking for a way to change certain system sound effects just before a battle and then change them back to the way they were before so that I can have individualized boss death sound effects for certain bosses. Any way to achieve this? Thanks for taking the time to read this!
  24. Hi I have a var with a huge string. Am try to make a max letter count for each line. Is work, but is cropped my word. How i can prevent Cropped words ? Like the red Arrow show.. Here how ma var are setup I use this myvar=myvar.match(/.{1,40}/g).join(' \n '); // The text string example in a var var TempDesscr = 'this is a test with text.match, but is cropping'; // Now replace the same var with the '\n'for break line eatch 40 letters TempDesscr=TempDesscr.match(/.{1,40}/g).join(' \n '); // and show function for the text description in picture bitmap $gameScreen.setDTextPicture('\\OW[6] ' + TempDesscr +' ', 36); $gameScreen.setFont('GameFont'); $gameScreen.showPicture(894, '', 0, 660, 485, 100, 100, 255, 0); Tanks a lot for helping guys
  25. Flare Notification - vs 3.0 Darkness Falls Terms: Credit must be given to me. Mit license means you can do what ever. free for commercial usage Flare Notifications allows you to create notification windows based on different events. So lets create a notification: FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]", stickToTop, fadeOutNearBottom);This creates a notification window that will scroll down the game window fading in and then out at a specified rate given by the options. As you can see we give the notification window some text. Optional values are stickToTop and fadeOutNearBottom which should be obvious what they do. fadeOutNearBottom is calculated based on a plugin setting which lets you calculate when it it should start fading out. All windows are added to a cue, first in first out. For example an event can have: FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]", false, true, {windoWidth: 900, windowX: 2, windowY: 90});FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]", true, false, {windoWidth: 900, windowX: 2, windowY: 90, fontSize: 20});// Options are passed in as an object:// windowWidth = The width of the notification window.// windowX = The x position of the window.// windowY = the y position of the window.// fontSize = the font size for the window.FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]");FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]");FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]");FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]");FlareNotification.notify("\\i[8] \\c[10]Hello World\\c[0]"); This adds ten windows to an event that will then all be called. ATTN! If you have 1 or more notifications and you open a menu, enter a battle. we will play the next set of notifications. If you then open a battle or a menu we will remove any notifications currently on the screen. This is similar behavior to the map name. Regarding windowY If you set the window Y to low or too high you may never see the notification because the window moved down the y axis and as it does it fades out over time. That time can be adjusted how ever. Event Based Notifications Now you can enable a set of options to turn on event based notifications for weapons, armor, items, xp, gold, hp, mp and so on. There are a ton of individual event notifications that you can turn on or off so that you are not creating events all the time that contain notifications after a party gains x item or loses x hp. These only trigger on events that require the player to some how activate them. They do not play in battle or in menus. Event based notifications have options for the way the window looks and behaves including width, font size, stay at the top, how long till next window and so on. These options are different then self created notification window options and are individual for each type of event notification. ATTN!! Assume you have 6 events that play (all at once) as the player triggers them. The notification messages are added to a queue. The events will play out, level messages and other types of messages will play out associated with that event. these messages are known as $gameMessage's. The notification event messages will play directly after according to how they were added to a queue. How to get the script? Download Here. FAQ: - How do I use this? Download the dist/ script or make a new JS file called: Flare-NotificationWindow.js and then follow the above steps. Do not forget to save and enable the script. - Are there incompatibilities? Not as far as I know? Post them if there is. Rules are: Screen shot of the error, console too if you have Yanflys core script. What you were doing, what caused the crash, what scripts you are using. - Can you add a feature? Yes. Just let me know what you want and ill consider it. - I found a bug! Follow the "Are there incompatibilities" rules for positing bugs. It helps me debug.