ia13ru
@ia13ru
0
Red Square AdventuresA Final Fantasy-type RPG, made in python!
(Quite badly)
1
0
0
0
I am having a problem with Tkinter
For some reason, an image I want to show up is not doing so. What is wrong?
(The code for the image is in Ani.py)0
1
0
Hi,
I am makin this game. I want to slow down the 'for i in range(3) ' loop in ' if key==""'. How do I do this?
Python
2
The huntA game where you, the blue square, have to run away from the red square.
221
4
2
I am making this small game. If you play for a while, you might notice this error popping up in the console. How do I fix it, if it even is fixable?
Ruby
3
Competitive hangmanIt is hangman for 2 players(needs one person to be judge)
224
0
3
12
Scrolling platformerThe name says it all!
1.4K
7
12
AssdonDiep It says Hmmmm.... We Couldn't Reach Your Repl
Make sure your repl has a port open and is ready to receive HTTP traffic.1 year ago
I have a question which is in this post. I am reposting this as it has been ignored.
The post
Thank you in advance. :-)
Python
MadMath123 You can't reference a variable name in Python. The best solution would to make an array of objects, like @ANDREWVOSS wrote. The vars() function is used to get all class vars of an object into one dict (useful for debugging or referencing). If you want to make another object the same way as another, the vars() function might be useful.2 years ago
ANDREWVOSS The best solution would be to create a list:
objects = [object1,object2,object3]
for object in objects:
object.function()
`2 years ago
I am trying to make the code beneath shorter.
class Thing:
#insert class here
from tkinter import *
#insert setup code here
#this is where the code I
Python
I have this function:
def draw():
#insert all of the variables being specified here
return self.canvas.create_rectangle(x1, y1, x2, y2, fill=c)
svensk007 I would use an import such as pygame (import pygame)
And then use pygame to draw it
Also I've used Tkinter before and it has a like 2000s era GUI so pygame again would probably be for the better even if you have to "learn" a new Library. Or if you need VSYNC use pyglet2 years ago
DynamicSquid I don't think there is a prebuilt function for it, so you might have to implement it yourself.2 years ago
A shooter which you can shoot by clicking and jump by pressing the space bar!
HTML, CSS, JS
Is there a function in web javascript that does what require() in node.js does?
notGilbert There is ES6 import / export, but it is only supported in some libraries
MDN
(not supported for internet explorer)2 years ago
SixBeeps No. If you need to use a third-party library on the client side, you'd provide a URL to the library source code through the script's src attribute.2 years ago
The title says it all! So how do I?
19ecal const { exec } = require("child_process");
exec("python file.py", (error, stdout, stderr) => {
if (error) {
console.log(error: ${error.message});
return;
}
if (stderr) {
console.log(stderr: ${stderr});
return;
}
console.log(stdout: ${stdout});
});
Try that2 years ago
How would I connect javascript to sqlite when Javascript is being used with HTML?
xfinnbar The short answer is, you can't. However there is a way around it using a server.
HTML/CSS/JS is a client. You need to connect to a server to get the page, database or any other type of dynamic content. Repl.it handles the server for you when you choose HTML in the languages menu. You'll need to write your own server.
From my experience, NodeJS and Python are the two best languages to write a server in, go for NodeJS if you care about a lot of performance, but for most tasks, Python will suffice.2 years ago
How would I put some SQL data on a HTML page?
InvisibleOne Do you mean something like this:
HTML:
JS:
sql_data = 'bla bla bla bla';
document.getElementById('data').innerHTML = sql_data;
`2 years ago
I am new to sql and I have 3 questions about it.
How would I put data in the cloud? Or could I just store it in a file for later use?
How would you us
Baconman321 Ok, so first things first, replit sqlite AFAIK doesn't allow remote connection (chezcoder and I tried this to no avail).
Second, sql is a query language that allows you to store data in a file on the server.
JavaScript is a client-side language, which means that it is not capable of accessing sql (for a good reason, too! People could use devtools to delete things from your database or add things too it, which could be quite the predicament).
To use sql, you need a server language (like NodeJS2 years ago
I am having problems with code which is detecting collision.
All JavaScript(which is most likely where the problems are) is in script.js.
I apologise
HTML, CSS, JS
migoyo Thanks for the blog loaded with so many information. Stopping by your blog helped me to get what I was looking for. เว็บแทงบอลที่ดีที่สุด7 months ago
TurboTurbojr Im trying to add collision detection to my game so the guy can hit the other guy and he dies. But i cant figure it out someone help?1 year ago
I am trying to make 2 objects with the same name, and are exactly the same. I am also trying to put it on a canvas with ctx.fillRect. How would I go a
HTML, CSS, JS
I have posted something on a problem I had.
It was simply said as a case of a repl.it bug.
I tried it in another compiler and I had the same problem.
Coder100 What do you mean another compiler?
Btw, instead of using console.log, you can also use alert:
let obj = {"a": "b"};
alert(JSON.stringify(obj, null, 2));
`2 years ago
I am doing this project. I think I want to log all the attributes in the console. Or is this what I am meant to do?
Tutorial I am following
Code: In s
Coder100 image
i see it just fine.
Because of the bugs in replit, if you go to a different page other than index.html, it won't log the results in that page.2 years ago