Its give a count of how many weeks in a year.
Orange Time System - Variables
JS Plugin Releases (RMMV)Thanks ! Nice plugin !
Uh, Hudell. I'm having the exact same problem as DarkSlayerEX was having...
Namely, while the Time System function as it should, the time variables do not change... and I'm using the newest version of this plugin.
Could you help me, please?
Namely, while the Time System function as it should, the time variables do not change... and I'm using the newest version of this plugin.
Could you help me, please?
I am having the exact same issue
Do you have any idea what is causing it?
I had the same problem. I fixed it. There's a small typo in the js code. If you look in the code where the $.configureVariables function is being defined the "secondVariable" is being used to calculate 90% of the other variables. I pasted FIXED code below.
Code:
/*=============================================================================
* Orange - Time System Variables
* By Hudell - www.hudell.com
* OrangeTimeSystemVariables.js
* Version: 1.3
* Free for commercial and non commercial use.
*=============================================================================*/
/*:
* @plugindesc Exports Orange Time System data to variables
*
* @author Hudell
*
* @param secondVariable
* @desc The number of the variable where you want to store the seconds
* @default 0
*
* @param minuteVariable
* @desc The number of the variable where you want to store the minutes
* @default 0
*
* @param hourVariable
* @desc The number of the variable where you want to store the hours
* @default 0
*
* @param dayVariable
* @desc The number of the variable where you want to store the days
* @default 0
*
* @param monthVariable
* @desc The number of the variable where you want to store the months
* @default 0
*
* @param yearVariable
* @desc The number of the variable where you want to store the years
* @default 0
*
* @param weekDayVariable
* @desc The number of the variable where you want to store the week day
* @default 0
*
* @param dayPeriodVariable
* @desc The number of the variable where you want to store the day period
* @default 0
*
* @param monthNameVariable
* @desc The number of the variable where you want to store the name of the month
* @default 0
*
* @param monthShortNameVariable
* @desc The number of the variable where you want to store the short name of the month
* @default 0
*
* @param dayNameVariable
* @desc The number of the variable where you want to store the name of the day
* @default 0
*
* @param dayShortNameVariable
* @desc The number of the variable where you want to store the short name of the day
* @default 0
*
* @help
* ============================================================================
* Latest Version
* ============================================================================
*
* Get the latest version of this script on
* http://link.hudell.com/time-system-variables
*
*=============================================================================*/
var Imported = Imported || {};
var OrangeTimeSystemVariables = OrangeTimeSystemVariables || {};
if (Imported["OrangeTimeSystem"] === undefined) {
console.log('Download MVCommons: http://link.hudell.com/time-system');
throw new Error("This library requires the OrangeTimeSystem!");
}
(function($) {
"use strict";
$.Parameters = PluginManager.parameters('OrangeTimeSystemVariables');
$.Param = $.Param || {};
$.Param.secondVariable = Number($.Parameters['secondVariable'] || 0);
$.Param.minuteVariable = Number($.Parameters['minuteVariable'] || 0);
$.Param.hourVariable = Number($.Parameters['hourVariable'] || 0);
$.Param.dayVariable = Number($.Parameters['dayVariable'] || 0);
$.Param.monthVariable = Number($.Parameters['monthVariable'] || 0);
$.Param.yearVariable = Number($.Parameters['yearVariable'] || 0);
$.Param.weekDayVariable = Number($.Parameters['weekDayVariable'] || 0);
$.Param.dayPeriodVariable = Number($.Parameters['dayPeriodVariable'] || 0);
$.Param.monthNameVariable = Number($.Parameters['monthNameVariable'] || 0);
$.Param.monthShortNameVariable = Number($.Parameters['monthShortNameVariable'] || 0);
$.Param.dayNameVariable = Number($.Parameters['dayNameVariable'] || 0);
$.Param.dayShortNameVariable = Number($.Parameters['dayShortNameVariable'] || 0);
$.configureVariables = function() {
if ($gameVariables === undefined || $gameVariables === null) return;
if ($.Param.secondVariable !== undefined && $.Param.secondVariable > 0) {
$gameVariables.setValue($.Param.secondVariable, OrangeTimeSystem.seconds);
}
if ($.Param.minuteVariable !== undefined && $.Param.minuteVariable > 0) {
$gameVariables.setValue($.Param.minuteVariable, OrangeTimeSystem.minute);
}
if ($.Param.hourVariable !== undefined && $.Param.hourVariable > 0) {
$gameVariables.setValue($.Param.hourVariable, OrangeTimeSystem.hour);
}
if ($.Param.dayVariable !== undefined && $.Param.dayVariable > 0) {
$gameVariables.setValue($.Param.dayVariable, OrangeTimeSystem.day);
}
if ($.Param.monthVariable !== undefined && $.Param.monthVariable > 0) {
$gameVariables.setValue($.Param.monthVariable, OrangeTimeSystem.month);
}
if ($.Param.yearVariable !== undefined && $.Param.yearVariable > 0) {
$gameVariables.setValue($.Param.yearVariable, OrangeTimeSystem.year);
}
if ($.Param.weekDayVariable !== undefined && $.Param.weekDayVariable > 0) {
$gameVariables.setValue($.Param.weekDayVariable, OrangeTimeSystem.weekDay);
}
if ($.Param.dayPeriodVariable !== undefined && $.Param.dayPeriodVariable > 0) {
$gameVariables.setValue($.Param.dayPeriodVariable, OrangeTimeSystem.dayPeriod);
}
if ($.Param.monthNameVariable !== undefined && $.Param.monthNameVariable > 0) {
$gameVariables.setValue($.Param.monthNameVariable, OrangeTimeSystem.monthName);
}
if ($.Param.monthShortNameVariable !== undefined && $.Param.monthShortNameVariable > 0) {
$gameVariables.setValue($.Param.monthShortNameVariable, OrangeTimeSystem.monthShortName);
}
if ($.Param.dayNameVariable !== undefined && $.Param.dayNameVariable > 0) {
$gameVariables.setValue($.Param.dayNameVariable, OrangeTimeSystem.dayName);
}
if ($.Param.dayShortNameVariable !== undefined && $.Param.dayShortNameVariable > 0) {
$gameVariables.setValue($.Param.dayShortNameVariable, OrangeTimeSystem.dayShortName);
}
};
// Updates the variables every in-game second
OrangeTimeSystem.on('changeTime', $.configureVariables);
})(OrangeTimeSystemVariables);
Imported.OrangeTimeSystemVariables = 1.3;
I activate the script and put 1 for variable for dayPeriodVariable:
I guest it's supose to contain a number between 1 to 4.(night,morning,daytime,evening)
But I added messagbox for see value inside this variable and it's alway stay at 0.
What I did wrong?
I guest it's supose to contain a number between 1 to 4.(night,morning,daytime,evening)
But I added messagbox for see value inside this variable and it's alway stay at 0.
What I did wrong?
There was a stupid bug on my plugin. It only worked if the secondVariable parameters was also used. I just fixed the bug, if you update the plugin it should work now.
ok thanks it's work now. Can I make a direct call on this variable for make change the day/time hour? I guess the OrangeTimeSystem.hour = 12; was th best option.
But can you tell me when start each period of the day? Im surprise they was not an option in parameter. Night 0 to 6? morninght 6.02 to 12???
I need this info please. That will be great to add them as parameter.
Little edit, this is more a recommandation for the days/night script of course.
But can you tell me when start each period of the day? Im surprise they was not an option in parameter. Night 0 to 6? morninght 6.02 to 12???
I need this info please. That will be great to add them as parameter.
Little edit, this is more a recommandation for the days/night script of course.
There are four parameters in the Time System plugin:
@param dayPeriod1Hour
@desc At what hour does night turn into early morning
@default 6
@param dayPeriod2Hour
@desc At what hour does early morning turn into day
@default 9
@param dayPeriod3Hour
@desc At what hour does day turn into evening
@default 18
@param dayPeriod4Hour
@desc At what hour does evening turn into night
@default 20
You can't change the variables directly, as your change will be overwritten by the plugin. You'll need to use the script call to change the hour.
@param dayPeriod1Hour
@desc At what hour does night turn into early morning
@default 6
@param dayPeriod2Hour
@desc At what hour does early morning turn into day
@default 9
@param dayPeriod3Hour
@desc At what hour does day turn into evening
@default 18
@param dayPeriod4Hour
@desc At what hour does evening turn into night
@default 20
You can't change the variables directly, as your change will be overwritten by the plugin. You'll need to use the script call to change the hour.
@Hudell Im trying to change the lightning from you light plugin with this variables, but i only find a solution to call a common event at a specific time but there are no "fade". At 6 oclock the common event get called and set the darkness instandly to 80 for example.
Could i do the change smoother? Like a fade ?
Could i do the change smoother? Like a fade ?
i want to get os's real time
i read your guude over and over again
but i havent know how to use your system
could you let me know how to use your system step by step?
get date and set to rpg mv's variable
thanks for your help in advance
i read your guude over and over again
but i havent know how to use your system
could you let me know how to use your system step by step?
get date and set to rpg mv's variable
thanks for your help in advance
Original thread: https://forums.rpgmakerweb.com/threads/orange-time-system-variables.46514/
