Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Genusis

Members
  • Posts

    38
  • Joined

  • Last visited

    Never

Everything posted by Genusis

  1. Genusis

    Runtime Error 91

    If you have not already added this then make sure you add Set TempPlayer(Index).Buffer = New clsBuffer to the Sub ClearPlayer as that will initialize the buffer for use.
  2. Genusis

    Sockets

    SocketWrench is just a C++ wrapper of winsocket and web protocols given by another library.
  3. Genusis

    Sockets

    If you want to know a base explanation of what winsocket is this best describes it. http://searchwindowsserver.techtarget.com/definition/Winsock Basically no matter what you plan on using unless you have something that can do I/O on the low end you are stuck using winsocket. Even lidgren uses winsocket for windows. It simply just wraps around winsocket and sets the socket protocol to use UDP instead of TCP. Lidgren simply adds their own security features and reliability features to UDP which normally does not have those types of features. UDP is faster than TCP but in most cases you should not use UDP for perfect reliability as if you use something like lidgren you may end up wasting extra bandwidth trying to get a packet from one point to another if the packet did manage to get dropped as UDP is very susceptible to this. For more information on UDP and TCP look to these links http://searchsoa.techtarget.com/definition/UDP http://searchnetworking.techtarget.com/definition/TCP UDP can be good if the packet can make it all the way through the first time as it can have a single large packet compared to multiple packets split up into the size of the computers MTU. This means TCP can have more overhead than UDP, but with TCP you are guaranteed that packets arrive in order and they have a smaller chance of being dropped by a server.
  4. Genusis

    Yuko banned.

    "you stoles it, the precious!"
  5. Genusis

    Map Converter

    @'Xlithan': > TILESHEET_WIDTH = 224 pixels for the tilesheet im using. Or do I divide 224 by 32 to get the correct TILESHEET_WIDTH? > > * * * > > Still get subscript out of range with this code. first of all 7 *32 is 224\. also make sure those maps exist in the folder before trying to read them and what line is the subscript out of range happening on exactly? if all else fails it might not be reading the data into the map so you may need to break point debug it to insure the data exists. If you need help with this i can help you.
  6. Genusis

    Map Converter

    youforgot to redim the oldmap tiles as well. just add this to it. ReDim oldMap.Tile(0 To MAX_MAPX, 0 To MAX_MAPY) also the 224 should be 7 as that's what the original amount of tiles there where in a tile sheet originally. other wise the math will not turn out correct. since the x and y are done by tile index rather than by actual size. so math wise ground being lets say 5 5 / 7 = 0 because of rounding. * 32 = 0 5 mod 7 = 5 * 32 = 160; now with what you did 5/224 = 0 becuase of rounding but 8/224 = 0 as well when it should equal 1 after rounding. while also 5 mod 224 = 5 but 8 mod 224 = 8 when it now when you do it like this with the new numbers 8 mod 7 = 1 * 32 = 32 8 / 7 = 1 * 32 = 32 which is the correct number of pixels to the tile's square. Though you can simply remove *32 to keep just the tile position then times it by 32 later that way you can make the x and y a byte
  7. Genusis

    Map Converter

    to get the Y you will need to do (Map.Tile(X, Y).Ground \ TILESHEET_WIDTH) * PIC_Y to get the X you will need to do. (Map.Tile(X, Y).Ground Mod TILESHEET_WIDTH) * PIC_X those based on the map tile position setup are how ground, mask and fringe are used within the old mirage based system. also sorry i thought you where converting from a map style which migth have had the variable names as ground and mask but has a x, y. I forgot the old mirage had a set integer for pixel position. oh and also ou have to set the array before you can load data into the array like Tile(0 To MAX_MAPX, 0 To MAX_MAPY) As TileRec otherwise you need to use a realloc on the tile to set it to its dimension before trying to load the data into it. ='] otherwise the tile index's are none existent on either side.
  8. Genusis

    Map Converter

    ignore this post I thought he was using a post that had ground set as a struct to x, y and tileset.
  9. Genusis

    Map Converter

    you will need to do something like if x < old_maxx and y < old_mapy then NewMap.Tile(x, y).Layer(1).x = OldMap.Tile(x, y).Ground NewMap.Tile(x, y).Layer(1).y = OldMap.Tile(x, y).Ground NewMap.Tile(x, y).Layer(3).x = OldMap.Tile(x, y).Mask NewMap.Tile(x, y).Layer(3).y = OldMap.Tile(x, y).Mask NewMap.Tile(x, y).Layer(7).x = OldMap.Tile(x, y).Fringe NewMap.Tile(x, y).Layer(7).y = OldMap.Tile(x, y).Fringe NewMap.Tile(x, y).Layer(1).Tileset = 1 NewMap.Tile(x, y).Layer(3).Tileset = 1 NewMap.Tile(x, y).Layer(7).Tileset = 1 NewMap.Tile(x, y).Type = OldMap.Tile(x, y).Type NewMap.Tile(x, y).Data1 = OldMap.Tile(x, y).Data1 NewMap.Tile(x, y).Data2 = OldMap.Tile(x, y).Data2 NewMap.Tile(x, y).Data3 = OldMap.Tile(x, y).Data3 else NewMap.Tile(x, y).Layer(1).x = OldMap.Tile(x, y).Ground NewMap.Tile(x, y).Layer(1).y = 0 NewMap.Tile(x, y).Layer(3).x = 0 NewMap.Tile(x, y).Layer(3).y = 0 NewMap.Tile(x, y).Layer(7).x = 0 NewMap.Tile(x, y).Layer(7).y = 0 NewMap.Tile(x, y).Layer(1).Tileset = 1 NewMap.Tile(x, y).Layer(3).Tileset = 1 NewMap.Tile(x, y).Layer(7).Tileset = 1 NewMap.Tile(x, y).Type = 0 NewMap.Tile(x, y).Data1 = 0 NewMap.Tile(x, y).Data2 = 0 NewMap.Tile(x, y).Data3 = 0 end if
  10. Well glad that you are feeling better about yourself and I hope everything will get even better for you from here on out.
  11. @'Dialectics': > I'm not even going to bother addressing you. Honestly, educate yourself before you say something quite so dense again. > > Here's how you can convert a 32 bit integer into a byte array (big endian): > > byte[] byteArray = new byte[4]; > for (int i = 0; i < 4; i++) { > bytes _= (byte)(integerToConvert >>> (i * 8)); > } > > You could also simply use Java's ByteBuffer class. > > I admit I was wrong. I forgot that Java supported bit manipulation. > anyways, its not worth doing this because the Java compiler automatically does this for you anyways.[Edit] > > Anyways the above code would be more efficient if you pre-created the buffer set a size to lets say a power of 2 and then checked that buffers size to what data is being added into it then resized to the next power of 2 and so on. its inefficient to resize or create a new array each and every time you need to add something into the array._
  12. @'Dialectics': > These comments are cringe inducing. > > Why are you using the PrintWriter? Just pack the data directly into a byte array using simple bitwise and shift operators. bitwise and shift operators only work on the bit level. This wont do you any good if you are trying to add data into a byte array. The closest thing you could do to get this to work in to use a memcpy function which can copy each byte into the array of data: https://gitlab.com/ascendingcreations/swift/blob/master/net/source/buffer_stream.c#L162
  13. that is also true as well marsh. Though a majority of the time most things can be private without breaking anything especially if you programmed it that way to begin with. I do however suggest to use private whenever possible. And also if your referring that to googles changes they made at one point. Those never broke anything. Oracle just through a fit because Google made certain functions private in the java libraries that was not being used directly, which did increase overall security of java on androids. Funny thing Oracle won the lawsuit and google was forced to change it back. Oracle never made those changes themselves. It is one of the few reasons i dislike Java and tend to not ever install it unless i have to to help someone or to play a game that uses java.
  14. Also to add the fact that making code private that should be rather than making everything public adds extra protection for your program. The public everything idea is one reason why Java is red flagged as a huge security hole. It is also a reason why Google when making android wanted to private functions to prevent known security holes from occurring. My advice is to do what PeRV did Panda and learn how to use modifiers how they should be and the reasons behind them if your going to program in any Language.
  15. In terms of language wise it probably isn't worth a majority of peoples time to even botherā€¦. My honest opinion its not worth wasting money on a vb6 game. especially that much money.
  16. Technically in order for this to work he will need to send a email himself via his administrative W3 email to Benjo, link , etc to approve the above. As they can not go based solely on Skype conversations or screenshots.
  17. Funny thing is people still do learn from this source. Anyways IF you honestly think that using a Long for everything out-weights everything so be it for you that 1 person. Other than that this is mostly based solely upon actual programming practices which do make a difference. I rather teach people the right way than say hey just change everything to a long because you know what. its the fastest variable out there for vb6\. I dislike that way of thinking.
  18. if you have lets say 200 users and use to use a byte but instead switch it to a long you now are using 800bytes of data. compared to 200 if you use a integer you only use 400bytes of data. This goes for many things within ANY Language. It wasn't solely meant for just mirage source based engines. Besides if your learning to program you should learn to do it in a proper way regardless of the source or outcome. This way whenever you decide to switch languages or go farther you already have these concepts in mind.
  19. I have to many to list XD soooo all of the above which they mention are pretty good.
  20. funny thing the speed enhancement from a long is only if you are using a 32bit processor. Its why 32bit applications run slightly slower on 64bit processors than on 32bit processors this is due to the registers being 64bit in size. Anyways speed wise integer to long on most processors will calculate around the same speed down to the microsecond on a 64bit system. regardless though you should not use a variable type bigger than what is needed if you are going to send the players data over the net or to other people. Also using a long over a integer will double the amount of space the stats will take up PER user. in turn your server and client will use much more ram based on the array of users you have setup and how many stats you have within those users. Overall its better to just use a integer. Also do not use a floating point for this in vb6 it will end up making it slower for regular adding and subtracting as they do not follow the newer IEEE standards for floating points which most newer processors use to speed up floating point calculations. Other than that here are the variable types and their equivalent bit sizes. Byte 0 to 255 8bits Integer -32,768 to 32,767 16bits Long -2,147,483,648 to 2,147,483,647 32bit Currency -922,337,203,685,477.5808 to 922,337,203,685,477.5807 64bit Floating points. single 32bits double 64bits Decimal 112bits So go with a integer. yes there will be a slightly decrease in speed but its worth the size.
  21. Genusis

    Overflow

    The overflow simply means that getplayerstat is returning a value larger than what TempPlayer(Index).END can hold. A way to fix this would be to change the variable End to something that can hold a larger value. for example a byte can not hold more than 255\. so if you are using a byte for END you might want to switch it to a integer or a long based on the size you truly need it to hold. http://www.developerfusion.com/article/32/data-types/
  22. that is just a false positiveā€¦ Unless of course your PC isn't infected with an actual virus which added itself to your exe. ;]
  23. You will most likely need to make a converter program which can connect to your mysql database and read and sends all the information from the binary files to your mysql database.
  24. Genusis

    Quest editor

    Sherwin the only reason why they go for the most feature rich engine is because they lack programming experience and would rather compile it once and set up the game without needing to change a ton of crap. My honest opinion is the more features the more buggy the engine will be. This also goes along with how hard it to to navigate and or learn from the said engine due to it having so many features. My advice is to learn how to program first of all, then take the necessary steps to find a team to do the things you do not want or have time to do like pixeling. Then go about working on your game from something with very few features like the old mirage source. This way you build your game around the way you want it to be like and to easily make it more unique. If you have a ton of games with the same features etc then you end up with RPG Maker games which rarely anyone plays because they are all the same. Big time feature rich projects should be stripped down and each part made into tutorials that the user can add and in the process allow them to learn to program. Those of which who do not want to learn should either decide to learn or be thrown under the bus unless they are willing to pay others to help them. Other wise you are not learning anything this way and you end up getting a crap amount of crap users who you have to fight with and heavily support. Especially those who do not want to learn and want you to do it all for them. This is just my opinion though.
×
×
  • Create New...