Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

VX Script Fixes (1 FIX)

Aeiras":25xp6vhw said:
Ok, I just got a new one tonight, involving the Scene_Battle. I set it up so a monster would drop an item 1/5 of the time. When we reach the end of the battle, I get an error on line 624 of the script, stating "too few arguments" if the item did indeed drop that fight.

The script: Scene_Battle
Line 624:      text = sprintf(Vocab::ObtainItem, item.name)

Sounds like you changed Vocab::ObtainItem and deleted the %s that was in the original line:

  ObtainItem      = "%s was found!"
 

korgul

Member

Hi! I'm (as probably the keenest analytical mind among you had allready inferred) korgul. I'm new to this incredibly helpfull and awesome forum, so I'm not quite sure that this is the right section to post on, but I think I found another bug in vx (aside from the one with variable. If  checked this forum before I would have spared myself a hell of trouble), or it's just that I'm incompetent, I coudn't tell.
Anyway, when I use the troops event, I think it does'nt work the condition that makes the event occor at turn x + 1(z). (ie, if i set up the event to start at tourn 0+1(x), or 2 + 2(x), every tourn or everu even turn, in other way, it just activate hymself the first time, instead of reoccourring ciclycaly).
Has anyone else sperimented this bug?
(sorry for the grammar, it's long since the last time I had to write in english, and, being  in office I haven't time to check it)
 
@mechacrash
I found the bug when I was working on my XP Party Changer. When you use the Call Script command and you set a variable to false, the game freeze. In the Interpreter, Part 7, Command 355:
Code:
# If return value is false
   if result == false
      # End
      return false
   end
I've simply removed this part.

EDIT:
I just realized that it has been fixed with the SDK.
 
I hate it when people think the "false freeze" feature is a bug.  How is it a feature and not a bug, you ask?  When RMXP's Interpreter class preforms an event command, it wants to know if the command was successful or not.  If the command was successful, it will move onto the next command.  Now if the command was not successful (IE returning false in the Script... command), it will try and re-run the command again, and again, and again until the command was successful.  Unfortunately, people thought that this was a bug because it "froze" the game, when reality the game could still be played. Try just putting false in a new XP project in a parallel process event and you'll see that you can still play.
So to those who think this is a bug, it's not.
 
Oh, well, thanks for the clarification! I knew about the successful/unsuccessful thing, I used the word "bug" simply because I've never been able to find another way to make it work.
That's a good thing to know.
 
@emil
Create new slot above 'Main' in Script Editor,
and add that script. :)

---------------------------------------------------
Here is the bug I found:

when you show animation on character,
and you move in the map that bigger than 17 x 13 which cause map to scroll.
The animation will move with the screen, instead of stay on character.

Here is the script to fix it. Basically, just put the animation's x/y update part in method update~
Code:
#=========================================================================
# â—
 
I've also found an error. A pretty annoying one. And I'll slap myself if it only happens to me...

If you want a vertical gradient for a bar, you put 'true' in the end right?
Well I've noticed if you put anything on the end it still gives a vertical gradient. I even tried putting false and even nil and it still does vertical.

E.g.
gradient_fill_rect(x, y, width, height, color, color2, false)
Still returns a vertical gradient

I just thought you guys should know... I don't have a clue what the coding is for gradient_fill_rect so I can't fix it ¬_¬
 
Yeah, Skykal. I got that error too. :D

Here is the little script to fix it~
Code:
class Bitmap
  alias wora_bug_bmp_gfr gradient_fill_rect unless method_defined?('wora_bug_bmp_gfr')
  def gradient_fill_rect(*args)
    args.pop if args.size == 4 || 7 and !args.last
    wora_bug_bmp_gfr(*args)
  end
end
 
Thanks ^_^
I've no idea how that works, but I hope it does xD
I guess that should probably go on the first page.

:EDIT:

Do you guys mind if I post these fixes on another webiste?
 
and i found the second xD

Code:
args.size == 4 || 7
must be
Code:
args.size == 4 || args.size == 7
or
Code:
[4,7].include?(args.size)
 
Well, I tested and it works fine. :)

Try to call this script:
Code:
# Test 7 Args
@win = Window_Base.new(0,0,200,200)
@win.contents.gradient_fill_rect(0,0,10,100,Color.new(0,0,0),Color.new(255,255,255),true)
@win.contents.gradient_fill_rect(20,0,10,100,Color.new(0,0,0),Color.new(255,255,255),false)
# Test 4 Args
@win2 = Window_Base.new(0,200,200,200)
rect = Rect.new(0,0,10,100)
@win2.contents.gradient_fill_rect(rect,Color.new(0,0,0),Color.new(255,255,255),true)
rect = Rect.new(20,0,10,100)
@win2.contents.gradient_fill_rect(rect,Color.new(0,0,0),Color.new(255,255,255),false)

Here is test for 6 and 3 args
Code:
# Test 6 Args
@win = Window_Base.new(0,0,200,200)
@win.contents.gradient_fill_rect(0,0,10,100,Color.new(0,0,0),Color.new(255,255,255))
@win.contents.gradient_fill_rect(20,0,10,100,Color.new(0,0,0),Color.new(255,255,255))
# Test 3 Args
@win2 = Window_Base.new(0,200,200,200)
rect = Rect.new(0,0,10,100)
@win2.contents.gradient_fill_rect(rect,Color.new(0,0,0),Color.new(255,255,255))
rect = Rect.new(20,0,10,100)
@win2.contents.gradient_fill_rect(rect,Color.new(0,0,0),Color.new(255,255,255))

And I just found out that if arguments are (rect, c1, c2, vertical), the vertical part will work and not need this fix.
So the fix can change to fix only 7 arguments (x, y, w, h, c1, c2, vertical)

Code:
class Bitmap
  alias wora_bug_bmp_gfr gradient_fill_rect unless method_defined?('wora_bug_bmp_gfr')
  def gradient_fill_rect(*args)
    args.pop if args.size == 7 and !args.last
    wora_bug_bmp_gfr(*args)
  end
end
 

arion

Member

It was mentioned i could request a bug fix in this thread;
http://www.rmxp.org/forums/index.php?topic=49462.0
The above is my support topic, with all the information I can provide. Any help is appreciated. ~.^

On a seperate request,
http://i81.photobucket.com/albums/j205/ ... /fudge.png[/img]
Since i updated my program to v1.02 (Yes the official release from enterbrain), play test, battle test, and any other in-editor auto-runs do not work.
The RMVX player will run if its clicked on in a project folder.
Again, a fix would be appreciated, i don't want to have to work around v1.01's many disgusting flaws.

I run XP.
 
I'm not sure if it could be the problem, but in the game's directory, you can find a .ini file which contains information on which DLL of the RGSS2 to use, and in the name of the DLLs the full version number is present. So the problem may be that it isn't updated, and the Game.exe or something else expects another DLL. The RGSS2 is located in your Program Files\Common Files or something similar, and only this may have been updated, and your game's .exe not. This is why I think that to be the problem.

Sorry, I can't test it, because I started this all RPG making with the most recent version, and did not have this problem.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top