# Coding Questions

**URL:** https://discourse.processing.org/c/processing/processing-questions/15.md?page=146

[Latest](https://discourse.processing.org/latest.md) · [Categories](https://discourse.processing.org/categories.md) · [Tags](https://discourse.processing.org/tags.md)

**Page:** 147

---

## [Storing String Data in Arrays?](https://discourse.processing.org/t/storing-string-data-in-arrays/9347)

<div class="topic-metadata">

**Author:** [@clevelandbrowns](https://discourse.processing.org/u/clevelandbrowns)\
**Replies:** 10\
**Last updated:** [March 19, 2019, 1:51pm UTC](https://discourse.processing.org/t/storing-string-data-in-arrays/9347 "2019-03-19T13:51:21Z")

</div>

Hi there–so I am trying to write something that can input text and then store what is there to an array. Most of the array tutorials I have seen are about numeric data. Is it any different for storing text? Furthermore, …

---

## [Recreating Breakout](https://discourse.processing.org/t/recreating-breakout/9356)

<div class="topic-metadata">

**Author:** [@DM\_Slippin](https://discourse.processing.org/u/DM_Slippin)\
**Replies:** 7\
**Last updated:** [March 21, 2019, 11:42pm UTC](https://discourse.processing.org/t/recreating-breakout/9356 "2019-03-21T23:42:19Z")

</div>

Hey there! I’ve been working on recreating the classic game, Breakout. As I’ve been working on it, I started working with creating the properties for the ball such that it would stick to the walls, could be aimed, and fi…

---

## [Moving line markers in a GUI](https://discourse.processing.org/t/moving-line-markers-in-a-gui/9489)

<div class="topic-metadata">

**Author:** [@iampadik](https://discourse.processing.org/u/iampadik)\
**Replies:** 4\
**Last updated:** [March 21, 2019, 4:56pm UTC](https://discourse.processing.org/t/moving-line-markers-in-a-gui/9489 "2019-03-21T16:56:19Z")

</div>

Hi all. So, this is a GUI I have made using Processing 3.5.3 in Windows7 (64 bit). I have an issue with having a continuously moving marker along with the mouse in the rectangle where I see the data. Currently, I have …

---

## [Car controlled by Keys](https://discourse.processing.org/t/car-controlled-by-keys/9509)

<div class="topic-metadata">

**Author:** [@RC75018](https://discourse.processing.org/u/RC75018)\
**Replies:** 1\
**Last updated:** [March 21, 2019, 2:34pm UTC](https://discourse.processing.org/t/car-controlled-by-keys/9509 "2019-03-21T14:34:53Z")

</div>

Hi Everyone, I am a newbie in processing. I have this mouse attracted object that i am trying to convert into a key arrows controlled algorithm. I want to keep this notion in pointing in the direction of motion but don’…

---

## [Delta time / day](https://discourse.processing.org/t/delta-time-day/9441)

<div class="topic-metadata">

**Author:** [@NAA](https://discourse.processing.org/u/NAA)\
**Replies:** 6\
**Last updated:** [March 21, 2019, 5:31am UTC](https://discourse.processing.org/t/delta-time-day/9441 "2019-03-21T05:31:45Z")

</div>

Hey everyone! Couple of newbie question here, I’ve look trough the forum but I didn’t find what I was looking for. I’m writing a simple countdown for a specific day. Question 1: Why processing doesn’t update the ima…

---

## [Trying to find a name in a table](https://discourse.processing.org/t/trying-to-find-a-name-in-a-table/9498)

<div class="topic-metadata">

**Author:** [@ctrembla](https://discourse.processing.org/u/ctrembla)\
**Replies:** 2\
**Last updated:** [March 21, 2019, 3:59am UTC](https://discourse.processing.org/t/trying-to-find-a-name-in-a-table/9498 "2019-03-21T03:59:06Z")

</div>

Hey, I’m making a card game & made a list of the cards in a table. I thought I could run through the list and match the card I want with the correct info in the table, but i’m getting the wrong info. I place Captain in, …

---

## [Color wheel / A self made function](https://discourse.processing.org/t/color-wheel-a-self-made-function/9281)

<div class="topic-metadata">

**Author:** [@Aryan\_Pandhare](https://discourse.processing.org/u/Aryan_Pandhare)\
**Replies:** 12\
**Last updated:** [March 20, 2019, 8:48pm UTC](https://discourse.processing.org/t/color-wheel-a-self-made-function/9281 "2019-03-20T20:48:26Z")

</div>

Hi everyone, I am new to processing and I want to know that how to we convert an angle to color of the circle in processing function. I already have a function that converts low-high to min-max, know as the linearScale(…

---

## [Electrical Circuit](https://discourse.processing.org/t/electrical-circuit/9483)

<div class="topic-metadata">

**Author:** [@TOMiKENi](https://discourse.processing.org/u/TOMiKENi)\
**Replies:** 5\
**Last updated:** [March 20, 2019, 7:34pm UTC](https://discourse.processing.org/t/electrical-circuit/9483 "2019-03-20T19:34:03Z")

</div>

I need help creating this electrical circuit but I do not understand how to make my ellipse follow my circuit rather than continuing in the one direction. Can anyone help me please? I have pasted my coding below: void s…

---

## [3D Textured rolling ball](https://discourse.processing.org/t/3d-textured-rolling-ball/9478)

<div class="topic-metadata">

**Author:** [@Thomzoy](https://discourse.processing.org/u/Thomzoy)\
**Replies:** 2\
**Last updated:** [March 20, 2019, 6:42pm UTC](https://discourse.processing.org/t/3d-textured-rolling-ball/9478 "2019-03-20T18:42:44Z")

</div>

Hi ! I’m trying to do a (seemingly) easy thing but I am having a lot of trouble doing it. I want to simulate a sphere rolling on a plane, with a texture on it. To do so I computed the vector around which the sphere sh…

---

## [Error Using Processing in Eclipse](https://discourse.processing.org/t/error-using-processing-in-eclipse/4720)

<div class="topic-metadata">

**Author:** [@Angle](https://discourse.processing.org/u/Angle)\
**Replies:** 16\
**Last updated:** [March 20, 2019, 9:51am UTC](https://discourse.processing.org/t/error-using-processing-in-eclipse/4720 "2019-03-20T09:51:51Z")

</div>

I’m trying to use processing in eclipse, and am getting an error. After making my main class extend PApplet, regardless of whether I change anything else or not, I get: “Exception in thread “main” java.lang.ExceptionIn…

---

## [Moving Around And Shooting](https://discourse.processing.org/t/moving-around-and-shooting/8652)

<div class="topic-metadata">

**Author:** [@Brandeeenie](https://discourse.processing.org/u/Brandeeenie)\
**Replies:** 42\
**Last updated:** [March 20, 2019, 7:02am UTC](https://discourse.processing.org/t/moving-around-and-shooting/8652 "2019-03-20T07:02:05Z")

</div>

//0: GUI //1: GamePlay //2: GameOver ArrayList\<astroid\> astroids = new ArrayList\<astroid\>(); ArrayList \<shot\> shots = new ArrayList \<shot\> (); PVector player, playerSpeed; float maxSpeed = 3; int Scene = 0; int astroid\_…

---

## [Need Help Animating This Drawing](https://discourse.processing.org/t/need-help-animating-this-drawing/9446)

<div class="topic-metadata">

**Author:** [@Mahubis](https://discourse.processing.org/u/Mahubis)\
**Replies:** 1\
**Last updated:** [March 19, 2019, 4:51pm UTC](https://discourse.processing.org/t/need-help-animating-this-drawing/9446 "2019-03-19T16:51:04Z")

</div>

float x; float theta =0; void setup() { size(600, 600); } void draw() { background(255); fill(0); strokeWeight(2); rect(30, 200, 100, 100); line(30, 200, 400, 200); line(50, 300, 400, 300); line(30, …

---

## [How to fix a suuuper slow sketch?](https://discourse.processing.org/t/how-to-fix-a-suuuper-slow-sketch/9412)

<div class="topic-metadata">

**Author:** [@Qualitykittenpainter](https://discourse.processing.org/u/Qualitykittenpainter)\
**Replies:** 1\
**Last updated:** [March 18, 2019, 2:21pm UTC](https://discourse.processing.org/t/how-to-fix-a-suuuper-slow-sketch/9412 "2019-03-18T14:21:36Z")

</div>

He guys, I made this sketch which is an animation with animals. Somehow it got really slow, and i know line 199 till 203 makes it slow down but i dont know how to fix it. what can i change to make it go normal speed. A…

---

## [How to check x,y of object?](https://discourse.processing.org/t/how-to-check-x-y-of-object/9345)

<div class="topic-metadata">

**Author:** [@Shadowoftime](https://discourse.processing.org/u/Shadowoftime)\
**Replies:** 4\
**Last updated:** [March 17, 2019, 11:29pm UTC](https://discourse.processing.org/t/how-to-check-x-y-of-object/9345 "2019-03-17T23:29:53Z")

</div>

Hello, I’m working on a game in processing and for the game I need to know each time the X and Y of a certain object, the same object constantly changing location and therefore I need you to tell me through which he will…

---

## [Image in for loop not showing](https://discourse.processing.org/t/image-in-for-loop-not-showing/9358)

<div class="topic-metadata">

**Author:** [@Orbital](https://discourse.processing.org/u/Orbital)\
**Replies:** 8\
**Last updated:** [March 17, 2019, 2:09am UTC](https://discourse.processing.org/t/image-in-for-loop-not-showing/9358 "2019-03-17T02:09:16Z")

</div>

So sorry for a stupid question, I’m quite new. I’ve looked around online but found no answer. For whatever reason, no image is getting displayed when running this. //variables PImage img; Boolean trainmode = true; Str…

---

## [Trigonometry: Compute a point location on an arc](https://discourse.processing.org/t/trigonometry-compute-a-point-location-on-an-arc/9191)

<div class="topic-metadata">

**Author:** [@solub](https://discourse.processing.org/u/solub)\
**Replies:** 14\
**Last updated:** [March 16, 2019, 9:12pm UTC](https://discourse.processing.org/t/trigonometry-compute-a-point-location-on-an-arc/9191 "2019-03-16T21:12:13Z")

</div>

Hi all, I would like to find a way to compute the location of p4 on the picture below. All I have is: the location of p1, p2 and p3 the radius (length of segment p2 - p3) the angle between segment p1-p2 and segmen…

---

## [Problem with movement of ball and its speed](https://discourse.processing.org/t/problem-with-movement-of-ball-and-its-speed/9229)

<div class="topic-metadata">

**Author:** [@Michalis](https://discourse.processing.org/u/Michalis)\
**Replies:** 3\
**Last updated:** [March 16, 2019, 4:18pm UTC](https://discourse.processing.org/t/problem-with-movement-of-ball-and-its-speed/9229 "2019-03-16T16:18:09Z")

</div>

Hello, I’m really new to Processing and programming in general so I’m having some hard time to realize my project. I’m kinda lost right now and I’d really appreciate some help. So, I’m having this code, in which I want …

---

## [Help needed "the function add does not exist"](https://discourse.processing.org/t/help-needed-the-function-add-does-not-exist/9329)

<div class="topic-metadata">

**Author:** [@Qualitykittenpainter](https://discourse.processing.org/u/Qualitykittenpainter)\
**Replies:** 3\
**Last updated:** [March 16, 2019, 11:13am UTC](https://discourse.processing.org/t/help-needed-the-function-add-does-not-exist/9329 "2019-03-16T11:13:14Z")

</div>

Hi there, I’am trying to make a animation with animals increasing in number. But i run in to an error :frowning: i now have one animal that is increasing in number ( katten) . but i want the “paarden” to do the same. …

---

## [Trigonometry help--find third point of the triangle](https://discourse.processing.org/t/trigonometry-help-find-third-point-of-the-triangle/9127)

<div class="topic-metadata">

**Author:** [@cras](https://discourse.processing.org/u/cras)\
**Replies:** 16\
**Last updated:** [March 15, 2019, 10:35pm UTC](https://discourse.processing.org/t/trigonometry-help-find-third-point-of-the-triangle/9127 "2019-03-15T22:35:28Z")

</div>

It’s been a few too many years since I took geometry, so I’ve been beating my head against what should be a simple problem :grimacing:. The goal, illustrated by the test sketch, is to calculate the 3rd point of a triang…

---

## [Problem making dissapair the Space Invaders enemys](https://discourse.processing.org/t/problem-making-dissapair-the-space-invaders-enemys/9332)

<div class="topic-metadata">

**Author:** [@wakonero](https://discourse.processing.org/u/wakonero)\
**Replies:** 1\
**Last updated:** [March 15, 2019, 7:46pm UTC](https://discourse.processing.org/t/problem-making-dissapair-the-space-invaders-enemys/9332 "2019-03-15T19:46:36Z")

</div>

Hello there! Im making a space invaders games, but im stuck trying to make dissapear the enemys of an a Array when they collision with the bullet, because i dont know how to number every enemy in the array to disapear.…

---

## [Where to place certain values in a chart code](https://discourse.processing.org/t/where-to-place-certain-values-in-a-chart-code/8749)

<div class="topic-metadata">

**Author:** [@Floralvxins](https://discourse.processing.org/u/Floralvxins)\
**Replies:** 5\
**Last updated:** [February 27, 2019, 8:38am UTC](https://discourse.processing.org/t/where-to-place-certain-values-in-a-chart-code/8749 "2019-02-27T08:38:53Z")

</div>

I’m having a bit of confusion on understanding just simple placement of my data. I’m making a pie chart based off of a data set so I know I have to plug them into where it says diameter and such but can someone help clar…

---

## [Wrapping a sentence, around a circle, letter by letter](https://discourse.processing.org/t/wrapping-a-sentence-around-a-circle-letter-by-letter/9056)

<div class="topic-metadata">

**Author:** [@DM\_Slippin](https://discourse.processing.org/u/DM_Slippin)\
**Replies:** 20\
**Last updated:** [March 15, 2019, 12:45am UTC](https://discourse.processing.org/t/wrapping-a-sentence-around-a-circle-letter-by-letter/9056 "2019-03-15T00:45:56Z")

</div>

Hi there! To cut to the chase, today I’ve signed up and submitted my code to hopefully have some answers pertaining to a project I’ve been working on. For a rundown of what I was trying for, I wanted to take a quote an…

---

## [Example 5-7 ~ BOUNCING COLOR ~ in Dan Shiffman book](https://discourse.processing.org/t/example-5-7-bouncing-color-in-dan-shiffman-book/9309)

<div class="topic-metadata">

**Author:** [@debxyz](https://discourse.processing.org/u/debxyz)\
**Replies:** 2\
**Last updated:** [March 14, 2019, 9:43pm UTC](https://discourse.processing.org/t/example-5-7-bouncing-color-in-dan-shiffman-book/9309 "2019-03-14T21:43:54Z")

</div>

When I run the code below (from Shiffman, p87, example 5-7, the color gradates back and forth only once. Why doesn’t it endlessly bounce back and forth? I thought if the “if” statement included an " = \* -1" this would …

---

## [Expanding circles, how do I do it?](https://discourse.processing.org/t/expanding-circles-how-do-i-do-it/9305)

<div class="topic-metadata">

**Author:** [@fraxinus](https://discourse.processing.org/u/fraxinus)\
**Replies:** 8\
**Last updated:** [March 14, 2019, 8:05pm UTC](https://discourse.processing.org/t/expanding-circles-how-do-i-do-it/9305 "2019-03-14T20:05:26Z")

</div>

How do I make a circle that starts as a dot and then keeps getting bigger until it disappears? Also then, how would I have more circles continuously appearing from that same point one after the other so I get what looks…

---

## [AES - Login algorithm](https://discourse.processing.org/t/aes-login-algorithm/8951)

<div class="topic-metadata">

**Author:** [@GWAK](https://discourse.processing.org/u/GWAK)\
**Replies:** 5\
**Last updated:** [March 14, 2019, 2:35am UTC](https://discourse.processing.org/t/aes-login-algorithm/8951 "2019-03-14T02:35:12Z")

</div>

Hi. I want to create a login system, not a different one. How would you not have a sample code created through a security algorithm? Please help me.

---

## [Need Help Understanding Code (Gravity)](https://discourse.processing.org/t/need-help-understanding-code-gravity/9217)

<div class="topic-metadata">

**Author:** [@gaggiatoraya](https://discourse.processing.org/u/gaggiatoraya)\
**Replies:** 3\
**Last updated:** [March 13, 2019, 9:00pm UTC](https://discourse.processing.org/t/need-help-understanding-code-gravity/9217 "2019-03-13T21:00:09Z")

</div>

I’m fairly new to processing and while attempting to code Gravity into my assignment I came across a template for coding gravity and acceleration. The problem is im not sure what the point of the last line y=height is. f…

---

## [Rotating an object based upon mouse position](https://discourse.processing.org/t/rotating-an-object-based-upon-mouse-position/9236)

<div class="topic-metadata">

**Author:** [@P1505](https://discourse.processing.org/u/P1505)\
**Replies:** 3\
**Last updated:** [March 13, 2019, 9:12am UTC](https://discourse.processing.org/t/rotating-an-object-based-upon-mouse-position/9236 "2019-03-13T09:12:33Z")

</div>

Hi all. I have a couple of questions I’m stumped on. I’m trying to make a basic dial control, where rotation outputs a +1 or -1 so I can update a number on the screen. Before I get to that though I’m struggling with the…

---

## [If two objects touch](https://discourse.processing.org/t/if-two-objects-touch/8876)

<div class="topic-metadata">

**Author:** [@LordCacops](https://discourse.processing.org/u/LordCacops)\
**Replies:** 3\
**Last updated:** [March 12, 2019, 9:11pm UTC](https://discourse.processing.org/t/if-two-objects-touch/8876 "2019-03-12T21:11:51Z")

</div>

Hello. I have objects in an array list. They are rectangular, but more complex than single rectangles. They are collections of rectangles. I want something to happen if two of these “Animal” objects touch. If these were…

---

## [Problem with keypressed](https://discourse.processing.org/t/problem-with-keypressed/9225)

<div class="topic-metadata">

**Author:** [@yonjukyu](https://discourse.processing.org/u/yonjukyu)\
**Replies:** 2\
**Last updated:** [March 12, 2019, 4:10pm UTC](https://discourse.processing.org/t/problem-with-keypressed/9225 "2019-03-12T16:10:02Z")

</div>

hello i want to make my “rect” moove when i press “LEFT” but with this code the rect is mooving even if nothin is pressed. (i used keyreleased because i want to press many keys at the same time) what’s wrong??: int x …

---

## [loadShape() throwing error when loading svg](https://discourse.processing.org/t/loadshape-throwing-error-when-loading-svg/9223)

<div class="topic-metadata">

**Author:** [@charly4710](https://discourse.processing.org/u/charly4710)\
**Replies:** 1\
**Last updated:** [March 12, 2019, 10:29am UTC](https://discourse.processing.org/t/loadshape-throwing-error-when-loading-svg/9223 "2019-03-12T10:29:03Z")

</div>

Hi, I struggle with loadshape() when loading certain svg files. the files are created in icograms.com, and are perfectly readable in browsers and in inkscape. parsed: m,51.4,41.9,c,0,.1,-.1.2,-.2.1,s,-.2,-.2,-.2,-.4.1…

[Previous page](https://discourse.processing.org/c/processing/processing-questions/15.md?page=145)

[Next page](https://discourse.processing.org/c/processing/processing-questions/15.md?page=147)
