Python Forum
Should i abuse the RAM or hard disc while creating big games?
Thread Rating:
  • 2 Vote(s) - 2.5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Should i abuse the RAM or hard disc while creating big games?
#1
My game will be very big,so should i use(abuse) the RAM or hard disc to store data?
If i use RAM,there is a limit that i can store.For a 32 bit computer,i think is 2^32 data.If it reached that number,the game will work horribly and eventualy crash.
If i use hard disc to store data and only open the file and get the value when needed ,then save the value back to the file and close it if it is not needed,it will cause my game to run super slow,because opening and closing file everytime i want to use a variable is a expensive task,but this will let my game world to be the first truly infinite game.(even Minecraft have farlands(the limit),but my method may be able to fix this.)
So what do you think i should do?
Reply
#2
If I were you I would choose to put it into the ram because you said that if you put it into the hard disc it would run very slow, but in the ram it would run fast until it reaches a limit. Just put as small amount of code so that it fits in the ram. The choice is up to you because its yours.  Hand
Reply
#3
I agree with SpeedyZap.   Think
Reply
#4
http://answers.unity3d.com/questions/408...000-1.html
https://0fps.net/2012/06/30/meshing-in-a...raft-game/
I'm sorry if my explanation is not good enough,the above website is exactly the same as my error,so please take a look,and try to teach me how to fix it in python?
Reply
#5
This is the classic problem of programming, and the source of Murphy's Law of Programming: The program will expand to use all of the memory available. How you are going to deal with that is going to depend very much on your particular application. You might shift stuff to RAM, you might shift from storing to calculating as needed, you might need to store your data more efficiently, you might need to calculate more efficiently. You might have to realize that what you want is just not feasible, and least in a given context. You're linking to a Unity site, you're probably using Pygame. If you're trying to recreate a specific game with its own implementation, that game may be using low level optimizations that a higher level game engine just isn't equipped to handle.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
Reply
#6
I dont have Unity but I think they have a limit on how many gameobjects you are allowed to have until its full. I have experiences in Blender and it said that it would be better to make mesh chunks that contain alot of blocks, so umm yeah...   Undecided
Reply
#7
(Apr-15-2017, 10:35 AM)SpeedyZapGaming Wrote: I dont have Unity but I think they have a limit on how many gameobjects you are allowed to have until its full. I have experiences in Blender and it said that it would be better to make mesh chunks that contain alot of blocks, so umm yeah...   Undecided

How to make mesh chunck in python with pyopengl , pygame and pyopenal?
Reply
#8
Oops I'm sorry, I thought you were using unity. But are you using pygame?

What type of game are you making? Platformer, flappy-bird style, etc.
Reply
#9
Yes,I am using pygame and pyopengl.

I am making game like minecraft.
Reply
#10
I guess you could try and make one set of mesh, grouped with other blocks? I have no Idea... Just trying to find out how.

I know!! make each block (If you are using blocks) bigger so that it holds more surface. Because if you make the blocks small the game has to render each block, when it is destroyed, placed or something like that. Basically make each block bigger?

Make the world have less blocks but they are then bigger than normal.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Question How to get a removable disc type in drive Daring_T 12 1,326 Feb-11-2024, 08:55 AM
Last Post: Gribouillis
  How hard is this? Phillips45 0 2,121 Jun-11-2018, 05:49 PM
Last Post: Phillips45
  Interaction with games such as BO3 nmills688 1 2,726 Oct-16-2017, 08:58 PM
Last Post: nilamo

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020