Author Topic: [XP] Random enemy parties  (Read 4465 times)

Offline gerrtunk

  • Awakened Visionist
  • **
  • Posts: 83
  • LV: 4
    • View Profile
[XP] Random enemy parties
« on: July 14, 2011, 04:37:29 PM »
Random enemy parties
Authors: gerrtunk
Version: 1
Type: Battle Add-on
Key Term: Battle Add-on

Introduction
This script let you use random enemy parties like games like Dragon Quest.

Features

You define a max, min, and the appear rate of each type of enemy in a set of maps, and
the rest is random. You also configure the battlers positions.

Screenshots
No.

Demo
No.

Script

(click to show/hide)

Instructions
In the script.

Compatibility
Any other enemy troop script.

Credits and Thanks
No.

Author's Notes

I will add more things when i need them in my projects(or i have time), so it will be updated. Again, feedback, bugs,retc, i will listen.
« Last Edit: July 28, 2011, 01:18:34 AM by ForeverZer0 »

LosZapatos

  • Guest
Re: [XP] Random enemy parties
« Reply #1 on: July 31, 2011, 10:32:32 AM »
I have an issue...

Script 'Random Enemies Parties' line 223: ArgumentError occurred.
wrong number of arguments(2 for 7)

Anything I'm doing wrong? And does the troop1 above :maps_ids mean anything particular? (I think I understand that :defined_positions represents the troop id in the database for how the enemy(ies) will be position and looks)

  Random_enemies = {
    :troop1 => {
      :maps_ids => [1,2,3],

TheMajesticYak

  • Guest
Re: [XP] Random enemy parties
« Reply #2 on: August 22, 2011, 03:03:43 AM »
I'm having real problems getting this script to work once I add a second enemy troop set.  I have two maps, map 6 is the main map and map 2 is submap (a cave on map 6).  Map 6 has troop1 as the only random encounter and Map 2 has troop2 as the only random encounter.  Here is how I have the troops in the class:

Code: [Select]
module Wep
  Random_enemies = {
    :troop1 => {
      :maps_ids => [6],
      :enemies_appear => [[1,8, false,false], [2,5, false, false], [3,3, false, false], ],
      :defined_positions => 1,
      :max_enemies => 5,
      :min_enemies => 1,
    },
    :troop2 => {
      :maps_ids => [2],
      :enemies_appear => [[1,5,false,false],[5,4,false,false],[6,2,false,false],[7,3,false,false],[8,3,false,false], ],
      :defined_positions => 2,
      :max_enemies => 5,
      :min_enemies => 1,
    }
  }
end

This works fine on map 6 when I only have troop1 defined.  I will only get random groups from 1-5 monsters in the positions I set for troop1 on the database tab for troops.  Once I add the definition for troop2, the random encounters on map 6 get all messed up.  I will now get as many as 8 monsters, and it will use positions from BOTH troop1 and troop2.  It's almost like it is trying to run both troops on map 6.  Although I will get up to 8 monsters, it never uses monsters 5,6,7, or 8, which are only defined for troop2.

Can someone explain what I am doing wrong?
« Last Edit: August 22, 2011, 03:31:20 AM by ForeverZer0 »

Offline gerrtunk

  • Awakened Visionist
  • **
  • Posts: 83
  • LV: 4
    • View Profile
Re: [XP] Random enemy parties
« Reply #3 on: September 18, 2011, 10:24:30 PM »
nothing, its a bug, i will patch it.
Man i forgot to correct that bug three times at least!  :shy: