That's what I did to a skyrim mod. I hated that mining was kinda pointless so without much knowledge I changed the counter of counter++ to counter+=0 so the counter would never end and you could mine forever Mwhahahaha
In response to Ter13
Ter13 wrote:
I ran into a weird habit:

powerlevel += 0

I have no idea what they thought they were trying to do,

I'm guessing that + sign was originally a / sign, and the operator was changed to prevent the implosion of our galaxy. So basically, whoever wrote this line of code saved the world. Show some appreciation.
In response to EmpirezTeam
Interesting theory there, yo. Why not delete the line, tho?
In response to NNAAAAHH
Or gray it out.
Back from the dead!

A recent post on Developer Help and it's replies struck me as a perfect example of a lot of the issues in rips here.

mob
proc
Statup(obj/O as num)
set background=1
if(src.Tessenka){return 0}
if(src.ByakuganUse){return 0}
if(src.SharinganUse){return 0}
if(src.usedhero){return 0}
if(src.MangekyouUse){return 0}
if(src.Cseal){return 0}
if(src.DemonUse){return 0}
if(src.shimon){return 0}
if(src.kyomon){return 0}
if(src.tomon){return 0}
if(src.sheimon){return 0}
if(src.keimon){return 0}
if(src.shomon){return 0}
if(src.kumon){return 0}
if(src.kaimon){return 0}
if(src.seimon){return 0}
src.Save()
start
if(src.points<=0)
src.points=0
return
if(src.Clan=="Puppet Master"||src.Clan=="Human Puppet")
switch(input(src,"Distribute Points.","[src.points] Points left",text) in list ("Taijutsu","Genjutsu","Ninjutsu","Speed","Puppetry","Save for later"))
if("Taijutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Tai+=D
src.mTai+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Ninjutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Nin+=D
src.mNin+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Genjutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Gen+=D
src.mGen+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Speed")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.speed+=D
src.maxspeed+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Puppetry")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Puppetry+=D
src.mPuppetry+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Save for later")
return 0
goto start

if(src.Clan=="Lee")
switch(input(src,"Distribute Points.","[src.points] Points left",text) in list ("Taijutsu","Speed","Save for later"))
if("Taijutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Tai+=D
src.mTai+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Speed")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.speed+=D
src.maxspeed+=D
src.points-=D
else
alert(src,"You don't have enough points!")
if("Save for later")
return 0
goto start
else
if(src.Clan!="Lee"||!src.Clan=="Puppet Master"||!src.Clan=="Human Puppet")
switch(input(src,"Distribute Points.","[src.points] Points left",text) in list ("Taijutsu","Genjutsu","Ninjutsu","Speed","Save for later"))
if("Taijutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Tai+=D
src.mTai+=D
src.points-=D
else
alert(src,"You don't have enough points!")

/*
if("Stamina")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.maxstamina+=D
src.points-=D
else
alert(src,"You don't have enough points!")
*/


if("Ninjutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Nin+=D
src.mNin+=D
src.points-=D
else
alert(src,"You don't have enough points!")

if("Genjutsu")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.Gen+=D
src.mGen+=D
src.points-=D
else
alert(src,"You don't have enough points!")

if("Speed")
var/D=input("How many points?","Points") as num
if(D<=0){return 0}
if(D<=src.points)
src.speed+=D
src.maxspeed+=D
src.points-=D
else
alert(src,"You don't have enough points!")

if("Save for later")
return 0

goto start


I'm going to clean this up, 'globalize' the copy/pasted code, and rid the code of the horrible abuse of goto instead of a proper loop.

mob
proc
Statup()
//Not sure how exactly obj/O as num works here or what it even does, so I removed it.
set background=1
if(src.Tessenka||src.EyeUse||src.AwakeningUse)
//not sure what tessenka is, or most of what I removed here
//Removing un-needed variables that can easily be condensed
//(all eye uses grouped into one and then cross-referenced with 'clan'
//will allow for the exact same result, with a lot less vars
//same for the 'demon' unlocks and whatnot.
return FALSE
//Even though FALSE compiles as 0, the usage improves readiblity
src.Save()
while(src.points)
//removing the label and following if() statement in favor of a proper loop
var/a=input(src,"Distribute Points.","[src.points] Points left",text) in list(src.UpgradableVars+"Save for later")
//instead of calling for each clan to see what they can select, then copy/pasting this code for every clan
//we'll make a variable for the mobs with clans and fill the list with the selections as needed
//we, instead of initiating the switch() proc, will opt to save the selection in a variable for later
var/D=round(input("How many points?","Points") as num)
//To clear our code up of the copy/paste mannerisms that're too common amongst rips
//we ask what on and how many points they wish to spend first
if(!D) break
//we're using break here to allow for the remainder of the proc to return as intended
//as it will end itself at the end of the loop anyway
if(D<0)D=-(D)
//Here, we check if the value is less than zero and invert the given value to make it positive
if(D>src.points)
//instead of telling the user to select a lower amount
D=src.points
//simply set the amount to the maximum allowed
if(input("Are you sure you want to spend [D] points on [a]?","Confirmation")in list("Yes","No")=="No")
//Making sure the decision was intentional will save a lot of grief for those people that hit
//a button mistakenly(never want to send someone $100 instead of $10)
continue
//By continuing inside of the while() loop, you start the loop over from start
switch(a)
//Now simply assign the points chosen to the chosen stat
if("Taijutsu")
src.Tai+=D
src.mTai+=D
if("Ninjutsu")
src.Nin+=D
src.mNin+=D
if("Genjutsu")
src.Gen+=D
src.mGen+=D
if("Speed")
src.speed+=D
src.maxspeed+=D
if("Puppetry")
src.Puppetry+=D
src.mPuppetry+=D
if("Save for later")
//you could check for this specific earlier, to save player time choosing the amount
//of points to use AND confirming the action
break
//cancel the while() loop, to prevent the points being taken.
src.points-=D
//by saving the 'D' var outside of the switch, we can globalize the removal of the points
break
//You can now break OR return from the while loop, to prevent further loops here


That's what I came up with, without changing the structure too much or spending more than five minutes on it. I didn't compile, but you get the jest(I hope).

By all means, if anyone here has anything wrong with the way I've redone that bit of code, reply. I welcome people who can correct my mistakes(so I can correct them myself in the future).
D can be negative or a decimal value. That's probably bad. Never trust players to input stuff correctly. Assume your player is a cat walking across the keyboard.
In response to Ter13
I have made the alterations, I didn't think of the decimal and forgot to add in a preventative to the negative values. Any other questions/comments/concerns/advice?
In response to NNAAAAHH
The stats could derive from a common stat datum.
imo

                if(!D) break
//we're using break here to allow for the remainder of the proc to return as intended
//as it will end itself at the end of the loop anyway
if(D<0)D=-(D)


would be
if(!D || D<0) break
In response to Mar big
Mar big wrote:
The stats could derive from a common stat datum.

Seems like overkill to me.

Though I do overkill set up functions for working with stats:

#define OP_SET 0
#define OP_SUB 1
#define OP_ADD 2
#define OP_MUL 3
#define OP_DIV 4

#define ROUND_NONE 0
#define ROUND_FLOOR 1
#define ROUND_CEIL 2

#define STAT_HEALTH "health"
#define STAT_CHAKRA "chakra"
#define STAT_STAMINA "stamina"

#define floor(x) round(x)
#define ceil(x) (-round(-(x)))
#define clamp(v,l,h) min(max(v,l),h)

mob
combatant
proc
/*@/mob/combatant/proc/changeStat()
@Usage: Use this function to change any stat but health, chakra, or stamina
@Arguments:
stat: One of (). The stat that will be changed.
amount: the amount to change the stat to/by
operation: One of OP_SET, OP_SUB, OP_ADD, OP_MUL, OP_DIV. The arithmetic operation to perform with amount as the operand. Default: OP_ADD
rounding: One of ROUND_NONE, ROUND_FLOOR, ROUND_CEIL. How to round the outcome of the change. Default: ROUND_NONE
minimum: Don't allow the new value to be smaller than this. Default: 0
maximum: Don't allow the new value to be greater than this. Default: positive infinity
@Returns:
The difference between the original value and the new value.
@Notes:
Use changeStatus() instead to change health, chakra, or stamina
*/

changeStat(stat,amount,operation=OP_ADD,rounding=ROUND_NONE,minimum=0,maximum=1#INF)
var/old = vars[stat]
var/change = old
switch(operation)
if(OP_SET)
change = amount
if(OP_SUB)
change -= amount
if(OP_ADD)
change += amount
if(OP_MUL)
change *= amount
if(OP_DIV)
change /= amount
switch(rounding)
if(ROUND_NONE)
change = clamp(change,minimum,maximum)
if(ROUND_FLOOR)
change = clamp(floor(change),minimum,maximum)
if(ROUND_CEIL)
change = clamp(ceil(change),minimum,maximum)
vars[stat] = change
. = change - old
In response to Kats
Kats wrote:

You're never going to delete it, no matter how much you try.. it always comes back.. always.
In response to Kozuma3
I saw no reason why it shouldn't accept negative values and just convert it into an acceptable answer. Just a matter of taste, I guess.
In response to Kats
In case you've missed every post I've made regarding this topic; it's not for you. I understand that we shouldn't support the development of rips, but as it stands now, that's only increasing the poor quality of these games, that flood the community. I would rather suck it up and try to improve the overall quality of these games by actually lending advice on the subject matter. If no one is actively telling these kids what's wrong with what they're learning, they'll keep learning to use that. Eventually, you'll get Zasif. Someone who seemingly has no idea what he's doing inside a source.
In response to NNAAAAHH
NNAAAAHH wrote:
In case you've missed every post I've made regarding this topic; it's not for you. I understand that we shouldn't support the development of rips, but as it stands now, that's only increasing the poor quality of these games, that flood the community. I would rather suck it up and try to improve the overall quality of these games by actually lending advice on the subject matter. If no one is actively telling these kids what's wrong with what they're learning, they'll keep learning to use that. Eventually, you'll get Zasif. Someone who seemingly has no idea what he's doing inside a source.

Have to agree there, however it's funny how changing around a few icons and copy/pasting a few things can land you to 50+ players o-o
In response to NNAAAAHH
I was just being facetious, NNAAAAHH. :) It was intended to be a more sarcastic "solution" to rips rather than a legitimate response. What you're doing here is better, at least. It's by no means the perfect solution, but anything to get people thinking about actual game development rather than a re-skin/remap.
In response to Kats
I didn't think you were being too serious, which is why I said "in case", just wanted to ensure the reason behind the topic was clear. I thought the topic might be controversial, since majority of the forum users just bash rips 24/7/365, instead of trying to change or improve things. We all know how bad these sources are and how bad it is for the people making these clones to not know what they're doing and simply learning off of these ripped sources.

@Kozuma

I find it 10* more hilarious that 45/50 of those players will swear it's the best game on BYOND and, no matter what, will try to bash you and anything you do if you tell them the truth about the game. All you need is a teenager "staff", all moody and whatnot, "OP" everything, that one tournament library(which I don't even think has a hub any more), several ripped codes to copy other rips, and some sort , of paypal donation/subscription shiz with bonuses to "keep development going and the "24/7 lagless" shell server up". Bam, most popular anime game available.
In response to NNAAAAHH
NNAAAAHH wrote:
@Kozuma

I find it 10* more hilarious that 45/50 of those players will swear it's the best game on BYOND and, no matter what, will try to bash you and anything you do if you tell them the truth about the game. All you need is a teenager "staff", all moody and whatnot, "OP" everything, that one tournament library(which I don't even think has a hub any more), several ripped codes to copy other rips, and some sort , of paypal donation/subscription shiz with bonuses to "keep development going and the "24/7 lagless" shell server up". Bam, most popular anime game available.

... ima do et
In response to Kozuma3
Kozuma3 wrote:
... ima do et

no you're not
In response to EmpirezTeam
EmpirezTeam wrote:
Kozuma3 wrote:
... ima do et

no you're not

Because I am.. Mwahahaha.
Page: 1 2 3 4 5 6