Jump to content

SHsuperCM

Members
  • Posts

    264
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by SHsuperCM

  1. It's ok, I think I'm on to something, testing now and will post here the solution for anyone that needs..
  2. Ok, so I wrote this: public void drawSplitString(FontRenderer fontRenderer, String str, int x, int y, int wrapWidth, float size, int textColor) { GL11.glScalef(size,size,size); float mSize = (float)Math.pow(size,-1); fontRenderer.drawSplitString(str,x,y,wrapWidth,textColor); GL11.glScalef(mSize,mSize,mSize); } inside the GuiScreen extension and put in GuiQuestBook this: this.drawSplitString(mc.fontRendererObj,showedQuest.getQuestDescription(),(this.width / 2) - 102,160,225,0.9f,Integer.parseInt("FFFFFF",16)); and it produced: Any ideas on how to fix it? EDIT, for some reason refreshing made up this: and now the text looks wierd..
  3. Ok, so I have GuiQuestBook.class that has some information in it like quests' names, levels, difficulty etc.. What it also has is a description that changes while doing the quest(it tells usally what to do), The problem is, the gui has a texture which is limited in size and some of the descriptions go beyond the texture. So, as the title might suggest, I'm trying to do a word wrap to keep the description within the texture. I've tried looking for ways to do it but found nothing that works.. One thing to keep in mind is that im scaling the text also using GL so I need it to work with any scale multiplier, I wrote this method on my GuiScreen extension: public void drawString(FontRenderer fontRendererIn, String text, int x, int y, float size, int color) { GL11.glScalef(size,size,size); float mSize = (float)Math.pow(size,-1); this.drawString(fontRendererIn,text,x,y,color); GL11.glScalef(mSize,mSize,mSize); } The width I'm aiming for with this is 225 pxls and the scale size I'm using is 0.9f btw..
  4. Yes.. stupid auto correct... I guess ill have to just place a button in hopes that no one uses its place.. But, is there a change you can show me an example on how you would register/use/imply the event on such button in the esc menu? Im not on pc do i cant test stuff...
  5. Giant there something that prevents overlapping?
  6. From what I understand, FML is supposed to make sure all mods can work together by adding its own ways of adding stuff..... I want to add a button element to the "esc menu" of the game that I can direct to my own gui.... The only way I know of to do that is by listening to gui changes and checking for that gui, then overriding it with my own clone of it... I looked a bit online with no luck of finding any answer so I came to the forum as usall...
  7. One thing you can do which is what I'm doing, Is make a dummy mod that does nothing for both server and client and make it so the server requires the mod to connect(built in with an universal mod) and only the friends have the mod.. its not that difficult as a hacker to still just make a mod with the same modID because it says it when you join without an modID I'm pretty sure.. but still you can do alot with verifying that way...
  8. I attempted again and again for the past days and couldnt figure it still.. I think ill just go with my previous plan which is using the achievement system to Do this... I dont know why capabilities are do hard to use really, usally i learn these things really quickly..
  9. Do I use the Entity provider is what you mean?
  10. But I'm stupid.... I need to see a code's prespective of using the providers to capabilities Sadly I also need to leave the DEV pc for an hour or 2.... I'll try to awnser stuff from my phone I guess...
  11. Do I need ICResearch to extend a custom provider? If so, what's a valid capability provider?
  12. First off, Thank you so very much for taking your time to explain this! It means alot to me that there is someone that is willing to help.. Now, I've read what you said about 4 times, Repeating sections again and again.. But I still struggle to understand.. Do I need to make a custom CapabilityProvider? How? Do I need to attach the Capability some how to the CapabilityProvider? How? Can you explain what you mean by "implementation of an interface"? I probably know this but dont know how its called... Do you know of any open source mods that do this? Let's say, Add an Capability to the Player/manipulating it/checking for it's values? I belive this is a "valid" capability? public interface ICResearch{ boolean getMainResearch(); }
  13. I really cant understand it! Please just give me a video that explains it really! Capabilities seem so complicated for me!
  14. Since I decided that capabilities are waay too complicated for me to handle, I'm now looking for a way to just save an NBT compound onto a file in the world folder(WORLD! NOT DIMENSION!) And read it later. This ofc will only be done on server side(And I'll mess later with packets)
  15. Lead me to I never find the docs understandable for some reason. Butt the Really helped me understand most of it.... Still, I'll have to expirement with it myself but thanks alot for the help!
  16. Oh gosh, ill never understand it... Is there a good tutorial for it somewhere?
  17. When yoou say objects you mean i can also save custom objects? Like, my own?
  18. Heard about that, can it store nbt compounds maybe? I know nothing about it... And will it save across game sessions?
  19. Maybe now that i look it seems that i might not want to use the achevement system.. What's a good way to store information on a player other than that? I want to "research" a part and be able to check anywhere if the player has researched A part.. #phonekeyboard
  20. Nvm, im a bit stupid... In class breaks i was coding on my laptop and figured it all.. Exactly what i needed! Apperently it was a text but the renderer type said enum model which is what confused me... I uses the bind TE to renderer and it works! Thanks anyways! Closed Btw im typing from my phone and its really hard
  21. In minecraft it is a tile entity and i copied almost everything except i found there is a renderer class that i dont know how to register...
  22. Maybe some information please? How would anyone help with what you just said? How'd you build? How'd you setup the workspace? Maybe a problem in main class? Show the main class maybe?
  23. What Issues do you have? Im using idea and it world perfectly... You maybe want me to explain what im doing?
  24. Im going to school now so i cant code :'( (From phone) But i started to copy stuff from the block and the tile entity... Is that all i need? Do i need something else to register it?
  25. First off I'd like if someone directed me to a good up to date achievement tutorial, That'd be lovely! Now, In alot of mods they have their custom tab in the achievement book and I want to make sure that my achievements have their own tab.. Secondly, I want an block to view achievements select them and "buy" them with EXP, I'll probably look at how the achievement gui does that but just to note that.. Now lastly I'll want to read if player got X achievement in another block, Should be noted that the second block will "craft" stuff but will agree with the server if the player unlocked the matching achievement for it... TNX for anyone willing to help!
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.