Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

395 Neutral

About kyanite

  • Rank
  1. kyanite

    Questioning The Setting In My Work

      First of all, I greatly enjoyed reading that.  Nicely done!   Secondly, I should mention that I'm chock full of anti-cough related products and operating on a low amount of sleep; if I say something that isn't coherent, my apologies.   Thirdly, I really like the idea of the setting.  That said, you might go into further detail about various setting related items.  For instance, what specifically does the tinkerer do and what kind of specific guns were the guards using (i.e. how Steampunk is this?)?  Similarly, what kind of architecture is the church and town in comparison (High Renaissance or early 15th century or maybe an older style that's somewhat out of place with the new for suspicious creepiness?)?  Blending Steampunk and Renaissance can work well but the locations in the story seem somewhat generic; there's nothing to suggest a "gap" because a lot of the action takes place in very time independent locations (inside a dark church, etc.).  It feels like, despite your intent on the Renaissance, you could potentially transplant the story all over history with the only requirement being after the advent of gunpowder and it would work well.  There's nothing wrong with that, per se, but I feel like it needs something to make it unique to the Renaissance period itself.   Where I'm a bit lost, however, is the main character.  In my opinion, you need to answer the question of why a thief would do what he or she did; that is, change from their life of crime to seeking redemption after a single event.  A true criminal would just run away and save themselves, why does this one choose to stay and fight?
  2. I just wanted to say that I've seen this project - off and on - for many years now and that y'all have done, and continue to do, a great job.  Keep up the good work!
  3. kyanite

    Billionaires vs Millionaires

    Hockey is that game that Canadians play on ice with ice skates and brooms, right?[/quote] For some reason I thought "No, that's Quidditch."   Which, of course, is preposterous; Canadians can't fly unless they use Air Canada.
  4. kyanite

    Who uses linux?

      People who use Linux are those who care to use it; mainly, individuals who know how.  It's not hard to add, either as a separate partition or on a secondary drive of some kind.  These days you can wedge a lot of them on thumb drives and use those instead.   And yes, I use Linux as my primary development environment and Windows for media related things (movies, games, etc.).       Agreed.  Hardware support on Linux has always been very hit or miss.  If you get lucky it's amazing but if you strike out it can be a truly horrible experience.   Also, yes, games on Linux are usually pretty solid if you manage to avoid the various driver-related pitfalls.  Wine itself has come a long way.
  5. kyanite

    Making Chunks load?

    Please use source tags (hit the button on the second row, far right side). Have you actually ascertained that this is a problem? If it is a problem, why not chunk load using threads? There are a myriad of transition schemes - such as keeping the world (nxm tiles) in memory with an additional +1 tile offset in each direction so the player can "move" and give you time to chuck the area they moved away from and preload whatever [non-visible] map they might be near. Even if you did this in a single thread I don't see it being an overly large problem [for you].
  6. Okay, here's the result: Page flipping: false Multiple Buffers: false FSEM Required: false Backbuffer accelerated: true Frontbuffer accelerated: true sun.java2d.opengl: null[/quote] Ah. The lack of page-flipping means you're likely to experience tearing. Not a whole lot you can do about that except try FSEM. Usually a faulty driver/low graphics card issue. For the Swing timer thing: I apologize, I must have missed where you stated that. For the JScrollPane issue: in most cases that indicates an initialization error somewhere that the addition of a non-custom component (whose default initialization helped kick Swing into gear, usually by auto-requesting a repaint) solved for you. No big deal.
  7. Things to watch out for: Swing Timer: Java timers are notoriously inaccurate and actually do not bear a guarantee beyond "will not fire below a certain threshold". Thus, you still need a traditional gameloop-esque mechanism to account for deltas. Also, I would not use a timer for a game loop and would instead perform the update manually. You can - and is a reasonable idea - to use a Timer as your time base (e.g. per tick update some delta time value and grab that) as that helps mitigate cross-platform timing issues but relying on Java to manage your loop for you is asking for problems, particularly under the discretion of Swing. Furthermore, as mentioned in a couple of research discussions, if your rendering becomes complex the timer thread may get bogged down in events waiting for your render to complete (or, depending on what you're doing, it might just wig out for no reason). Furthermore, it is important to remember that the entire point of a BufferStrategy is for you to manually control the buffers; it doesn' t make a lot of sense to grab that manual control and then immediately hand it back off to Swing. You would be better off just using paint and pumping repaint events. Hardware acceleration: HA is a tricky subject with Java. Realistically, whether or not you get it is at the discretion of the JVM and the system you're using. To my knowledge, the only reliable way to accelerate a drawing context without using VolatileImage directly in Java2D is to use full-screen exclusive mode and remains the only way to do so on older systems, since FSEM reserves the drawing context for your application only. Newer systems shouldn' t have that issue but it still remains a difficult thing to guarantee on an end user. Things to check: Check the value of the sun.java2d.opengl property. It will likely be null but it's still worth doing so. Check your buffer capabilities and ensure it supports page flipping and has multiple buffers. Grab both the front and back buffer capabilities and ensure they check out as well. E.g. [source lang="java"]// check System.out.println("Page flipping: " + strategy.getCapabilities().isPageFlipping()); System.out.println("Multiple Buffers: " + strategy.getCapabilities().isMultiBufferAvailable()); System.out.println("FSEM Required: " + strategy.getCapabilities().isFullScreenRequired()); System.out.println("Backbuffer accelerated: " + strategy.getCapabilities().getBackBufferCapabilities().isAccelerated()); System.out.println("Frontbuffer accelerated: " + strategy.getCapabilities().getFrontBufferCapabilities().isAccelerated());[/source] As an example, the above on my system returns: True True False True True Things I would try: Lose the JScrollPane. Ensure your context is accelerated by checking the above. If FSEM returns true then you must enable fullscreen exclusive mode to be accelerated. If any of the others return abnormal results then, unfortunately, there's not a lot you can do to fix that manually other than playing Jeopardy! with various graphics configurations. If sun.java2d.opengl returns false (instead of null) then I would try passing that as a VM argument with the value of true and see if that improves anything. Ditch the timer. Use a while(true) loop and stagger your player updates yourself (use nanoTime()) and don't forget an event listener so you can kill your app. If you do not experience tearing then your problem is with Swing's EDT. I assure you that is a battle you will lose horribly so I would suggest reverting to a more traditional game-loop and moving on. For what it's worth, this is why a lot of people prefer to use LWJGL or Slick2D over Java2D. You can still use simple draw commands without needing to battle AWT/Swing at the same time. Edit: Spacing.
  8. kyanite

    swing or not to swing

    Frankly, I'm always of the opinion that learning a language's core libraries is never a bad thing. Even though Swing is now considered obsolete - and is being replaced by JavaFX - much of the methodology (such as the threading model) is largely the same, so knowing one puts you in a good position to understand the other. However, if you're just going to be doing Java2D and then progress to LWJGL (or JOGL) with no interest in non-game UI development, then I wouldn't worry about it until you find you need it. Most of Swing's issues involve large scale UI applications; it's easy enough to just "wing it" for something like a simple map editor.
  9. Depends on how you're using the API. Straight from the example in the Javadocs, you'd do something like: LuaValue globals = JsePlatform.standardGlobals(); LuaValue sqrt = globals.get("math").get("sqrt"); LuaValue print = globals.get("print"); LuaValue d = sqrt.call( a ); print.call( LuaValue.valueOf("sqrt(5):"), a ); It looks like LuaValue is your transport to the Lua layer - it contains most of the overloads you'd need. You grab the function you want and then execute a call on it with the arguments you wish to pass.
  10. For your first question/example, yes, that will work as long as you ensure the text area is valid before you try to use it. As for your second question: public class Object1 { // this can also be private if you wish public JTextArea textArea; // the object that uses the text area private InnerObject object2; public Object1() { // do some kind of initialization of the JTextArea, e.g. textArea = new JTextArea( .. ); // pass it to the object that needs it object2 = new InnerObject(textArea); } } public class InnerObject { // our own version of the text area private JTextArea myTextArea; // using different names to make them clear for this example public InnerObject(JTextArea param) { this.myTextArea = param; } // use your text box public void doSomethingClever() { this.myTextArea.append("Converting file please wait\n"); this.myTextArea.setCaretPosition(this.myTextArea.getText().length()); } } Just be sure that the text area is initialized before you pass it, and that you don't accidentally destroy it before the InnerObject instance is done with it (for whatever reason). As per my initial comment in that bullet point, you could do the same thing with an Object1 instead of a JTextArea and use a getter to obtain the text area as well.
  11. Assuming (from your description) you have: public class Object1 { public JTextArea textArea; private InnerObject object2; } then either: textArea needs to be made static, thereby you may call Object1.textArea to obtain the reference to the JTextArea. Do understand what static means before you do this. object2 needs a reference to it's containing Object1, thereby it may call obj1Instance.textArea or you can just pass the JTextArea itself. The easiest way is via InnerObject's constructor. Technically you could also use [non-static] inner classes to get around this but imo that's rarely a helpful solution.
  12. kyanite

    Interface Tagging?

    Plus, languages with reflection have attributes for this sort of thing.[/quote] Ah, I see. I apologize, then, as - upon reading the Wikipedia article j-locke linked - I realize I don't use markers like that at all, for the reasons you mentioned (and that I've discovered in practice. Anyone who has worked with an object/primitive boundary has tried it at some point ...). In my defense, I like to use markers as a sort of programmer-level metadata and documentation for a specific attribute or feature that I know won't change - a basic example would be java.util.RandomAccess. For everything else (including serializabiliy) annotations are much better (as are the tools for using them). I'm in complete agreement with the inherent evil then, heh.
  13. kyanite

    Interface Tagging?

    I'm curious what the "counter" argument was, obviously made by your unnamed assailant? As for marking, I find it quite useful but the use cases tend to be rather rare. There is, in my opinion, a difference between a true marker interface and an interface that is, for whatever reason, simply empty.
  14. kyanite

    Easy Physics Library for Java?

    I've been looking for information of two physical libraries (JBox2D and JBullet) and the truth is that, I find no information about them, there is no documentation or any decent tutorial that can be followed, anyone know any other? T[/quote] They both say - very explicitly - that nothing was changed in the C-to-Java port and therefore to consult the base (read: the C or C++ library) documentation for all examples and issues. Fuzzy was Kevin Glass' small wrapper around Box2d (for Slick -> use Mercurial to check it out and Ant to build it) which might be useful.
  15. kyanite

    Current Fantasy MMORPGs?

    Good man. Also, Aion just went F2P - it's not amazing, but it's fun if you don't try to take it too seriously. Who doesn't love wings?
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!