Addon [1.7.10] Amun-Ra 0.4.8 - Now with Motherships

Discussion in 'Addons and Resource Packs' started by pra, Oct 18, 2015.

  1. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    #1 pra, Oct 18, 2015
    Last edited: Jun 23, 2017
    Gabs9999, SteveKunG, genius64 and 3 others like this.
  2. BlesseNtumble

    BlesseNtumble Member

    Joined:
    Nov 1, 2014
    Messages:
    297
    Likes Received:
    69
    If I understand correctly, this is a new solar system?
    If so, how do you render red ring planets another solar system?
     
  3. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    lol, YOU told me how to do it.

    In the SystemRenderEventHandler onRingRender, you call this for your CelestialBody:

    Code:
    protected void drawAsteroidRings(CelestialBodyRenderEvent.CelestialRingRenderEvent.Pre renderEvent, CelestialBody aroundBody) {
         
         Vector3f mapPos = renderEvent.parentOffset;
         
         float xOffset = (float) mapPos.x;
         float yOffset = (float) mapPos.y;
         
         if (FMLClientHandler.instance().getClient().currentScreen instanceof GuiCelestialSelection)
           GL11.glColor4f(0.7F, 0.0F, 0.0F, 0.5F);
         else
           GL11.glColor4f(0.3F, 0.1F, 0.1F, 1.0F);
      renderEvent.setCanceled(true);
      GL11.glBegin(GL11.GL_LINE_LOOP);
    
      final float theta = (float) (2 * Math.PI / 90);
      final float cos = (float) Math.cos(theta);
      final float sin = (float) Math.sin(theta);
    
      float min = 0;
      float max = 0;
       
      if(aroundBody instanceof Planet) {
         min = 72.F;
         max = 78.F;
      } else if(aroundBody instanceof Moon) {
         max = 1 / 1.5F;
         min = 1 / 1.9F;     
      }
    
      float x = max * renderEvent.celestialBody.getRelativeDistanceFromCenter().unScaledDistance;
      float y = 0;
    
      // outer ring
      float temp;
      for (int i = 0; i < 90; i++)
      {
      GL11.glVertex2f(x+xOffset, y+yOffset);
    
      temp = x;
      x = cos * x - sin * y;
      y = sin * temp + cos * y;
      }
    
      GL11.glEnd();
       
      // inner ring
      GL11.glBegin(GL11.GL_LINE_LOOP);
    
      x = min * renderEvent.celestialBody.getRelativeDistanceFromCenter().unScaledDistance;
      y = 0;
    
      for (int i = 0; i < 90; i++)
      {
      GL11.glVertex2f(x+xOffset, y+yOffset);
    
      temp = x;
      x = cos * x - sin * y;
      y = sin * temp + cos * y;
      }
    
      GL11.glEnd();
       
      // inner red area
      GL11.glColor4f(0.7F, 0.0F, 0.0F, 0.1F);
      GL11.glBegin(GL11.GL_QUADS);
    
      x = min * renderEvent.celestialBody.getRelativeDistanceFromCenter().unScaledDistance;
      y = 0;
      float x2 = max * renderEvent.celestialBody.getRelativeDistanceFromCenter().unScaledDistance;
      float y2 = 0;
    
      for (int i = 0; i < 90; i++)
      {
      GL11.glVertex2f(x2+xOffset, y2+yOffset);
      GL11.glVertex2f(x+xOffset, y+yOffset);
    
      temp = x;
      x = cos * x - sin * y;
      y = sin * temp + cos * y;
      temp = x2;
      x2 = cos * x2 - sin * y2;
      y2 = sin * temp + cos * y2;
    
      GL11.glVertex2f(x+xOffset, y+yOffset);
      GL11.glVertex2f(x2+xOffset, y2+yOffset);
      }
    
      GL11.glEnd();
      }
    It works on moons, too:
    [​IMG]
     
  4. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    [​IMG]
    [​IMG]
    [​IMG]

    Now, let's see if I manage to add solar collector fields instead of the regular ones...
     
    Ezer'Arch likes this.
  5. Vigilantecow

    Vigilantecow Member

    Joined:
    Oct 5, 2013
    Messages:
    446
    Likes Received:
    116
    I'm very impressed by the render of the solar system from Anubis. Very pretty.
     
  6. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    Is it sad that I like the methane pigs and the 'explode on oxygen contact' the most? xD
     
  7. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    hehe :D

    well, I'm not sure if I can make this actually work. Still fighting against structure generation (I think I actually understood it this time!), will try the exploding thing after that
     
  8. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    Meh, still seems like an awesome idea with just a little 'detail' feature that give a bit of life to the mod... I do know one thing for sure, if you do get it working and release this later on im definatly bringing some methane pigs to the overworld for experi- uh, farms! I definatly mean farms, look no further into the failed logic of the previous sentance >.>
     
  9. LokeYourLord

    LokeYourLord Member

    Joined:
    Feb 25, 2015
    Messages:
    93
    Likes Received:
    3
    Hmm, if you would do this right, you could actually name your planets after the Stargate Computer naming system, and let the Goa'uld rule over specific planets, like Anubis or Ba'al over some of the planets :) (Would fit nice with the SGCraft or LanteaCraft mod to then). You can then basicly make the Goa'uld the boss mobs on those planets or so :D
     
  10. Rabid_Potato

    Rabid_Potato Member

    Joined:
    Dec 5, 2014
    Messages:
    18
    Likes Received:
    4
    Awesome! I'm working on my own addon as well, actually.

    If you ever need any help, throw me a PM on here.
    I'll be glad to help!
     
  11. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    Making good progress with worldgen. After a lot of raging I decided to completely disregard everything Minecraft and Galacticraft do about villages and do my own thing. This is the result:
    2015-10-24_20.58.45.png 2015-10-24_20.59.03.png
    I'll tell you, adjusting block rotation metadata is a pain in the ass...

    edit @LokeYourLord:
    Hmm, I don't want to do too much Stargate stuff besides small references. But I definitely want to add pyramids and jackal/dog-headed guys as mobs. I suspect stargate-like portals would be quite a pain in the ass, too...

    edit2: added a config option to use advanced machines, too:
    2015-10-24_22.06.23.png

    edit3: WOOHOO, I did it!
    2015-10-24_23.56.56.png
    2015-10-24_23.57.05.png
    Making mobs blow up isn't that difficult after all :D
     
    #11 pra, Oct 24, 2015
    Last edited: Oct 24, 2015
    Ezer'Arch, SteveKunG and InsanityPie like this.
  12. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    You good sir, are a god o.o

    Also, on the Stargate topic... why not instead of adding your own portals, add special compatibility for the SGcraft or Lanteacraft mod? You can generate those mods stargates on your planets randomly, should be interesting to come across one while exploring
     
  13. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    Meh, now if the stupid pigs would spawn again... After debugging into Minecraft code, I wonder how anything can be spawned, like, ever...
     
  14. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    I know what you mean, im a beginner at java and my attempts at making a galacticraft addon wasn't very good since even I could tell the way minecraft uses code is all sorts of wonky hacks o_O
     
  15. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    Oh my effing god, yesterday I debugged until 5am without understanding ANYTHING, and in the end it was just a typo, Material.glass instead of Material.grass...
     
  16. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    I know what you mean... ive been tinkering with the 4 space source code and I did the same thing, just instead of grass/glass mine was accidently spelling hera as hear in ONE spot.

    Just that one typo took down all the crafting recipes I added since they relied on 'heraIngot' and boy did I feel stupid when I finally found the source of the problem... 4 hours, 4 frickin hours debugging a single typo ;-;

    Lesson of the day: When coding, a single typo can destroy your day if it goes unnoticed ._.
     
  17. Rabid_Potato

    Rabid_Potato Member

    Joined:
    Dec 5, 2014
    Messages:
    18
    Likes Received:
    4
    I've done the same thing trying to add a planet. (I'm fairly new to GC API). Incredibly annoying, but it goes.
     
  18. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    Im new to modding in general but ive got the basics of java down pretty good so far(just now getting into the advance stuff like meta data and events). Right now im just experimenting with what I know to see what I can accomplish, figured since Matt discontinued 4 space and open sourced it that I would see if I can tinker with it to learn some new stuff and possibly continue the addon later when im good enough to match his current code... right now im still a java noob so im learning a bit faster from studying how Matt coded certain things and trying to accomplish similar stuff with new code.

    Honestly, its a pretty good way to learn since I learn more hands on and im good at improvising so it's perfect for me. It's like learning to knit with a type of string from an old piece of fabric, horrible medaphor but it fits I guess xD

    Although im learning how difficult debugging can get sometimes... trying to implement a Hera dimension for Matts hera registry wasn't to hard since I used Elipse as a base and added my own code for specific things like biome decorators(ores and stones) and stuff like that but since im still learning about meta data and events I haven't figured out how to add trees, surface generation, custom grass, or multi biomes like im planning to... ill figure it out eventually but thats for later.

    [​IMG]

    Practically everythings a placeholder at the moment but I personally think it's coming across pretty well for my first ever attempt at a dimension!(even if it's currently piggy backing off Matts Elipse provider at the moment, gotta make my own later when I figure out how)
    ...that fact it's stable enough to not crash is actually pretty shocking shocking to be honest o.o
     
  19. pra

    pra Member

    Joined:
    Mar 7, 2015
    Messages:
    332
    Likes Received:
    116
    Trying to implement one of my own suggestions for GC:
    2015-10-29_22.18.57.png
    Not really good to see, but it's a fully functional raygun. It can be reloaded in an energy storage module/cluster, or crafted with a battery, which even gives you back the old battery!

    What I would like for this would be some input of how much damage it should do and how often it can fire when fully charged. Right now it needs about 3 shots for a skeleton and consumes 500 energy per shot of 15000 total, that makes 30 shots.

    I guess I'll implement the CryoGun, make rubys and cryogems generate on some planets, and then make a first alpha release
     
  20. InsanityPie

    InsanityPie Member

    Joined:
    Jun 18, 2014
    Messages:
    132
    Likes Received:
    25
    From the sound of it, the raygun is pretty balanced at the moment but maybe you can make it upgradable with certain materials?
    Something like: Tier 1(first raygun) takes 5 hits to kill a skeleton, tier 2 takes 3 hits to kill the skeleton, and tier 3 takes 1 hit. All of the tiers can use the same amount of energy per shot(500) with each upgrade giving the gun more energy storage, the first can be 15000 like currently with each tier adding another 5000 so at tier 3 the gun has 25000 energy storage and a high attack damage... of course to balance it the upgrades need better materials each tier to craft and some materials might be rare or only obtainable from dungeons
     

Share This Page