Results 1 to 6 of 6
  1. #1
    totalspelnerd is offline Member
    Join Date
    Mar 2012
    Location
    Sweden
    Posts
    88
    Rep Power
    0

    Default [Help] Easy way to create new Entities (mobs) for my Game

    First of all, I have no idea if this is the right place to post this on the forum. Sorry if I posted this in the wrong section.

    I'm creating a game right now and I'm kinda stuck at the entities. I want a easy way to add new Entities. Instead of going through 3-5 classes and change certain numbers. It's really hard to explain what I want to do. I want to make adding entities to work for game expansions or mods.

    Ask me any questions for additional information and I will try to explain them to you. If you want code for something just ask for it.

  2. #2
    Join Date
    Apr 2013
    Posts
    41
    Rep Power
    0

    Default Re: [Help] Easy way to create new Entities (mobs) for my Game

    Why not make a method that takes in an int and that int is how many 'entities' you want to spawn?

  3. #3
    totalspelnerd is offline Member
    Join Date
    Mar 2012
    Location
    Sweden
    Posts
    88
    Rep Power
    0

    Default Re: [Help] Easy way to create new Entities (mobs) for my Game

    oh, I didn't mean spawning enemies in a level, I meant creating a totally new one with new properties. Lets say I publish a game with only 3 monster in it and want to publish a expansion pack with 5 more monsters. I don't want to go into my core game with 3 monsters and add more. I want to be able to create a new jar file or zip file that contain the monsters and load them without opening my core game code. One example could be ModLoader for MineCraft, if you know what it is.

  4. #4
    kjkrum's Avatar
    kjkrum is offline Senior Member
    Join Date
    Apr 2011
    Location
    Tucson, AZ
    Posts
    1,060
    Rep Power
    6

    Default Re: [Help] Easy way to create new Entities (mobs) for my Game

    You could define each monster in an XML file or tag, and add monsters by publishing new XML files.
    Get in the habit of using standard Java naming conventions!

  5. #5
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,947
    Rep Power
    19

    Default Re: [Help] Easy way to create new Entities (mobs) for my Game

    You need to look into how to write your code to allow for things like plugins or mods.
    I think this is likely to be a Google task for you. It's not a small thing to achieve.

    Or go down the slightly easier route suggested by kjkrum. For that one you would need to put the work into defining your monster model such that it was flexible enough to allow you to model most of the things you want.
    Please do not ask for code as refusal often offends.

    ** This space for rent **

  6. #6
    totalspelnerd is offline Member
    Join Date
    Mar 2012
    Location
    Sweden
    Posts
    88
    Rep Power
    0

    Default Re: [Help] Easy way to create new Entities (mobs) for my Game

    Okay, I'll look into creating a pluggable program. Thanks for your tips :D

Similar Threads

  1. Missing Entities
    By Farscience in forum Java 2D
    Replies: 12
    Last Post: 09-27-2012, 07:33 AM
  2. What to use to create a game?
    By Tombomb in forum New To Java
    Replies: 7
    Last Post: 01-13-2012, 08:41 PM
  3. Easy Clip2D Game Engine now posted
    By rdjava in forum Reviews / Advertising
    Replies: 3
    Last Post: 06-03-2011, 05:24 PM
  4. Easy Clip2D Game Engine now posted
    By rdjava in forum Java Gaming
    Replies: 2
    Last Post: 06-03-2011, 05:18 PM
  5. Replies: 0
    Last Post: 06-14-2010, 05:21 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •