Jump to content
MakeWebGames

bluegman991

Members
  • Posts

    394
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by bluegman991

  1. Are you new at vb or did it not really take you 20 minutes to make that. (hence the sarcasm)
  2. I thought I hated minecraft too. But, after playing it a few times I decided it wasn't so bad. If only it were possible to have kick-ass graphics and not be limited to blocks for a game like this.
  3. I believe it's only ie6 that doesn't have max-width.
  4. What DJK said^^ You could create a css class like this: (changing max width/height to whatever you prefer) img.bbimg { max-width:500px; max-height:500px; }   and add class="bbimg" to the img tag.
  5. Good read, very informative.
  6. http://collabedit.com/ There's another one that has been out for a while. I've found a few good uses for this tool and can say it is quite handy. Haven't used it enough to see it's flaws, so I couldnt't say which one is better, but they seem to have pretty much the same features.
  7. So... A monster in a jar? I can see you put a lot of effort into it, and it looks pretty good. Just a few things that catch my eye when I look at it. First the jar. It needs some characteristics. Like smudges, cracks, old paint, faded marker writing, or partially torn off labels. (BTW I just guessed its a jar. It just looks like one from the close up.) Why? Because right now it barely seems like any type of cylindrical tube. It just looks like you just went into Photoshop and drew 2 slanted lines and filled it in with a partially opaque yellow. Then distorted the bottom pipe but left the top pipe as it was. It even looks like the monster is a floating object sitting behind the jar. The feet... They are only horrible because they have minimal detail. The skin texture... I have seen a few species preserved in jars. And the ones that I have seen who had skin. There skin was not visibly shining (light did not bounce off of it) while submerged in the liquid. And I don't believe any type of skin would be shiny after sitting in some type of fluid for more than a few hours. The skin texture actually makes the model look like it is a solid plastic toy. Last but not least. You did great on the head and arm area, but the leg and hip area need more attention because it seems like instead of having bones it looks like his legs are pretty much solid (like plastic). This could probably be solved with a better texture. Other than that the render looks pretty good. Great Job!
  8. The code below should work. You didn't do as djk mentioned and also you had your color changer if statement in wrong place.   [noparse]function hof_level() { global $db, $ir, $c, $userid, $myf; print "Showing the 50 users with the highest levels <table width=75% cellspacing=1 class=tablehof><tr style='background:gray'> <th>Rank</th> <th>User</th> <th>Level</th> </tr>"; $q = $db->query("SELECT u.*,g.* FROM users u LEFT JOIN gangs g ON g.gangID=u.gang WHERE u.user_level != 0 $myf ORDER BY level DESC,userid ASC LIMIT 50"); $p = 0; while ($r = $db->fetch_row($q)) { $p++; if ($p % 2 == 0) { $color = 'FFFFFF'; } else { $color = '000000'; } if ($r['userid'] == $userid) { $t = "<b><font color=red>"; $et = "</font></b>"; } else { $t = ""; $et = ""; } print "<tr style=background-color:#$color> <td>$t$p$et</td> <td>$t{$r['gangPREF']} {$r['username']} [{$r['userid']}]$et</td> <td>$t{$r['level']}$et</td> </tr>"; } print "</table></div><div><img src='images/generalinfo_btm.jpg' alt='' /></div></div></div></div></div></div>"; }[/noparse]
  9. The alt property is for the alternate text that will show in the event that: the page is rendered before the image is loaded, the viewer restricts images from being loaded, or if the image data is corrupted. There are more reasons the alternate text will be shown but those are probably the most common.
  10. There are 2 reasons I can think of for a someone to do a csrf attack on text rpg game. One is to bot their account. The other is to trick another user into requesting a page on your site (from another site) while they are logged in. (e.g. to withdrawl and send all money to someone, attack stronger player, etc...) If they are smart enough to make a bot then they are smart enough to get around a csrf key plainly put in the html. So this will not protect against someone botting their self. Leaving you very vulnerable to the 2nd reason. You can check the "$_SERVER['HTTP_REFERRER']" variable as a quick replacement. However this value is set in the header and can easily be changed. Unless you are using another method to check for csrf's, then you are leaving anyone who uses your site vulnerable including players and staff. And when your users are vulnerable then so is your site. But the last thing you would wan't is the person doing the csrf attack to get wind of the link to make their self staff.
  11. He knows that. What he's trying to figure out is why it's NOT updating to 3.
  12. Could we get the structure of the "gradient" field? Also you should combine all these queries into 1.   $result=mysql_query("UPDATE `grpgusers` SET `points` = `points`-2000, `colours` = '$colours', `gradient` = '3' WHERE `id` = '$player'");
  13. Ok so gamble sold it to you. Then you tried to sell it to someone else knowing it was neither of yours to sell?
  14. ie uses this css property for opacity   [color=#070606]filter: alpha(opacity=50);[/color]   so u will need [css]hr { filter: alpha(opacity=10); opacity: 0.1; }[/css]
  15. Lol sorry when typing I tend to use both bit and byte as if the were the same, it's a bad habit because I only do it to type one less letter, hoping that most people will know what i'm talking about. I didn't mean that you should create something to validate the whole file. With the precautions I put in my first post, it wouldn't even be necessary. I was just pointing out that almost anything can be faked, and that if you really wanted to positive of what was being uploaded, then you would have to check the whole file byte by byte. Yes it would be time consuming to make and memory consuming to execute. I wouldn't even recommend it. But, I'm just saying if you really wanted full control over what is and what is not being uploaded then you would want to do this. And yes, getimagesize does check the headers. But that's not all it does. It has to find the meta data then in the meta data it has to find the image size. Basically this precaution is to check if a part of the image file structure is there and is valid. But, why would you do all of that when you already know that the mime type is invalid? More time and memory wasted on a possible hacker.
  16. It's an extra precaution. And there's nothing wrong with taking extra precautions just to be safe. Besides... Not everyone is a hacker. A legit user may try to upload a file type that you do not want uploaded. And right there if the content-type is invalid you can catch it right there and tell them that it's invalid, without having to go any further or use a more memory intensive function. The first 8 bits of a file can be faked just as easily as the content-type, especially in a php file. I have just created a php file where php thought the mime type was image/png, this file also passed the getimagesize test, and passed the exif_imagetype. Also a lot more than the first 8 bits, and a lot more than the last 8 bits of the file were valid png bits, so it would have passed the 8 bit test also. But I would have been saved because I would have had the execution of php scripts disabled in the particular folder. Really... Code which can contain any ascii character coming in any order can be faked (like a compressed image, which like spud said most are compressed) So the only way that I can think of to be sure is to actually check every bit of the file. But really the extra precautions are for different lvl hackers. There's the lvl1 hacker that changes file extension and tries to upload. //file fails all tests. The level 2 hacker who tries to change the content-type. // passes some tests Then theres the lvl 3 hacker who will go into the code. //can pass all tests depending on tests given. So basically the more safe you want to be, the more memory intensive the tests will be. Doing a lvl 3 hacker test to catch a lvl 1 hacker is like calling S.W.A.T. to catch someone who stole a salt and pepper shaker from a restaurant. Time and memory could have been saved.
  17. Extra steps you can go through: In the upload script, "$_FILES" gives you the mime of the uploaded file. Make Sure the mime is equal to "image/<subtype>". If you are getting the image from another website, get headers will work, you may have to doo a little parsing (not much) to get the "Content-Type" ------ Directly after the upload. Check to make sure exif_imagetype(path_to_file) and getimagesize(path_to_file) does NOT return false. ------ Disable php from being ran in the directory which you are storing images. This is done in an htaccess file stored in that directoy (or in a parent directory with directory association (example: <directoy path_to_directory>)). Settings for .htaccess should be something like the following
  18. You hit the nail on the head. I too like the constant action of cod. (I am kind of an impatient person. Which also means I like to run and gun and constantly be in the action.) I do sometimes play bf though. When I feel like I wanna drive or shoot form a tank or helicopter I will play bf3. If I feel like I want to do some sniping, and I do love sniping, I will play bf3. But if I want constant action, which I prefer over anything, I will play cod.
  19. When you say html5. Do you mean using the html5 DOM, or the html5 canvas?   Making it look human ish? Wouldn't that be the responsibility of the animation? Pathfinders will be very intensive depending on how many paths there are and where you search.   That estimate is pretty off. Both C++ and client side javascript can loop a few million times per second.   Yea I could do it... But what I was trying to figure out is why are you doing it. I have no estimate, but lets just say a lot of dedicated programmers have the skill to do put these things together in a short period of time. (Lol, getting more off topic.) Any way, was just trying to figure out what more your engine had to offer besides what you are thinking about while making it.(frame rate, collision detection at pixel level, fractional pixel movements, shaders, particle engines...physics engine, path finding algorithms.)   You said you were using an engine to implement those features, so i didn't need to explain their complexity.   Again are you using DOM or Canvas? Also is it going to be 2d or 3d?
  20.   Lol. Whats with all of these engines your using? particle engines? physics engines? Can you create a particle engine? Can you create a physics engine? (I says jokingly.) Basically what you said in your first post is you should not be using the engine if you could not create it. But whether you can create it or not engines are put there to save you the work of doing certain tasks. Realistically the main requirement you should have when using the engine is knowing how to use it, what it does, and how it reacts. As of js being harder than php? What aspects did you find harder. Syntax? API? Cross Browser Compatibility? Scope? Other? By the way... Specifically what language is this graphical engine being made in? Client Side(Web Browser) js or some other language/tool using js. Collision detection? Not hard Fractional pixel movement? As long as the language you are using supports it. Doesn't really take that much math skill. Path finding? Not hard. Its mainly a matter of knowing where the object is not allowed or can not pass. Then looking for alternate paths. Frame Rate? Can be kept stable by knowing how to deal with highly intense animations, graphics and other tasks. Particals? Physics? Shaders? Already done by use of engine. Not saying it's easy.. But it's something most good math scholars can do. It's Off-Topic but just trying to figure out what exactly you are aiming at with your engine... As graphical engine doesn't exactly point it out.
  21. bluegman991

    Error help

    You are setting $_POST[fee] to a boolean when you do $_POST['fee']=preg_match(...);   Therefore if $_POST[fee] is not being posted or contains characters other than digits it will be false. Then you check to see if $_POST[fee] is empty. Which is basically like doing if(empty(false)) ... Which will have a result of false. Actually there is a built in php function which does the exact same thing as your regex, except it is much better, performance wise. You should be using something like this... [noparse]$_POST['fee']=array_key_exists('fee',$_POST) && ctype_digit($_POST['fee']) ? round($_POST['fee']) : false; $_POST['autoroll']=array_key_exists('autoroll',$_POST) && ctype_digit($_POST['autoroll']) ? round($_POST['autoroll']) : false; if(array_key_exists('Create',$_POST) && empty($dice)) { if($_POST['fee']===false) { echo "You must enter a starting fee."; } }[/noparse]   Also check to make sure the input element name in your form has the same casing as the key your are pulling in php. They must use the same case. P.S. I don't know how you go about defining $dice or if $_POST[Create] is being submitted, but I put it in there assuming you are correctly handling them.
  22. I'd say its worth $100 at the most. Which you should be able to get back from ads and such over the life of skyrim. Since elder scrolls isn't like cod releasing a new game every year it will last a bit longer (About a good 3-4 years).
  23. Deja Vu! I swear I seen another thread were someone posted a query to store the location of jquery in the database.
  24. 2 problems. First, you are trying to pass a for loop as a value. Second, you are not specifying an identifier.
  25. You can do all your pre-configuration before the document loads. Like: Math Send ajax requests to other pages Parse data (cookies and other js environment data) Retrieve data (cookies and other js environment data) That way when the document loads all of your data will be ready for placement or whatever you plan to do with it after the DOM loads.
×
×
  • Create New...