GML Patch v4.0.1 Now Available
Well I just finished working on a slight update to GML Patch earlier and now here’s the release. This really is a really minor update but hey, it’s something, right? All of the changes lied in the Update.exe file. (Updated source included) The main issue I saw was when it would launch, the window would only show after the update was completed, thus leaving the user clueless for a moment as to what’s going on.
List of Changes…
- Fixed issue where window would appear after update is completed instead of during it
- Removed changelog button by default (can be easily re-inserted in VB.NET)
- Revised the updater window design
Great Performance with a Lower FPS
Probably the biggest problem and set-back in Spherack Reloaded’s progress so far is the amount of lag that occurs while playing online with multiple players. Tons of information processing contributes to a significant drop in frames-per-second and the game becomes basically unplayable. However, after thinking for a bit, the idea hit me. What if I could make the game run a few calculations to adjust the speeds of objects to how they’ll normally appear at a full FPS? Simple really, all I had to do was divide the max FPS of the room by the current FPS. Looks like this:
speed = 5*(60/fps)
In the above scenario, 5 is the current speed of the object, 60 is the maximum frame-rate of the room (adjust to match yours or you’ll have weird results) and fps is the current FPS.
Seems to be working fine for me so far.
Projectile Speed on Mouse Position
Something I’ve been working on lately in one of my games is working in dynamic projectile speeds so players can strategically toss grenades to where they need to go rather than having to find some way to make the default speed work for them. So in my case, a player wants to throw a grenade to where their cursor is positioned. What I did was set up the angle calculations which is the easy part, though then there’s speed afterwards.
var mspd; //Creates the temporary value, mspd
mspd =(point_distance(x,y,mouse_x,mouse_y)/16); //Sets mspd to our needed speed
The above GML finds the distance between the source of the projectile and your mouse cursor, then divides by 16 to adjust the returned value to a usable speed (otherwise it’d go quite fast) Continue reading »
Wall
: I read a few topics. I respect your work and added blog to favorites.
: Hey, this is crazy that yu made your own site. Nicely done.
: You're funny. +1
